Home | History | Annotate | Download | only in patches
      1 Index: source/i18n/msgfmt.cpp
      2 ===================================================================
      3 --- source/i18n/msgfmt.cpp	(revision 83674)
      4 +++ source/i18n/msgfmt.cpp	(working copy)
      5 @@ -769,12 +769,13 @@
      6              DateFormat *fullDateTemplate = DateFormat::createDateInstance(DateFormat::kFull, fLocale);
      7              DateFormat *defaultTimeTemplate = DateFormat::createTimeInstance(DateFormat::kDefault, fLocale);
      8              DateFormat *shortTimeTemplate = DateFormat::createTimeInstance(DateFormat::kShort, fLocale);
      9              DateFormat *longTimeTemplate = DateFormat::createTimeInstance(DateFormat::kLong, fLocale);
     10              DateFormat *fullTimeTemplate = DateFormat::createTimeInstance(DateFormat::kFull, fLocale);
     11  
     12  
     13              appendTo += COMMA;
     14              if (formatAlias == *defaultDateTemplate) {
     15 +                // default is medium. no need to handle medium separately.
     16                  appendTo += ID_DATE;
     17              }
     18              else if (formatAlias == *shortDateTemplate) {
     19 @@ -782,11 +783,6 @@
     20                  appendTo += COMMA;
     21                  appendTo += ID_SHORT;
     22              }
     23 -            else if (formatAlias == *defaultDateTemplate) {
     24 -                appendTo += ID_DATE;
     25 -                appendTo += COMMA;
     26 -                appendTo += ID_MEDIUM;
     27 -            }
     28              else if (formatAlias == *longDateTemplate) {
     29                  appendTo += ID_DATE;
     30                  appendTo += COMMA;
     31 @@ -798,6 +794,7 @@
     32                  appendTo += ID_FULL;
     33              }
     34              else if (formatAlias == *defaultTimeTemplate) {
     35 +                // default is medium. no need to handle medium separately.
     36                  appendTo += ID_TIME;
     37              }
     38              else if (formatAlias == *shortTimeTemplate) {
     39 @@ -805,11 +802,6 @@
     40                  appendTo += COMMA;
     41                  appendTo += ID_SHORT;
     42              }
     43 -            else if (formatAlias == *defaultTimeTemplate) {
     44 -                appendTo += ID_TIME;
     45 -                appendTo += COMMA;
     46 -                appendTo += ID_MEDIUM;
     47 -            }
     48              else if (formatAlias == *longTimeTemplate) {
     49                  appendTo += ID_TIME;
     50                  appendTo += COMMA;
     51 Index: source/i18n/ucol_sit.cpp
     52 ===================================================================
     53 --- source/i18n/ucol_sit.cpp	(revision 83674)
     54 +++ source/i18n/ucol_sit.cpp	(working copy)
     55 @@ -239,7 +239,7 @@
     56              spec->variableTopString[i++] = readHexCodeUnit(&string, status);
     57          }
     58          spec->variableTopStringLen = i;
     59 -        if(i == locElementCapacity && (*string != 0 || *string != '_')) {
     60 +        if(i == locElementCapacity && *string != 0 && *string != '_') {
     61              *status = U_BUFFER_OVERFLOW_ERROR;
     62          }
     63      } else {
     64