Index: modules/locale/locale.admin.inc
===================================================================
RCS file: /cvs/drupal/drupal/modules/locale/locale.admin.inc,v
retrieving revision 1.1
diff -u -r1.1 locale.admin.inc
--- modules/locale/locale.admin.inc	8 Jan 2010 13:32:43 -0000	1.1
+++ modules/locale/locale.admin.inc	8 Jan 2010 18:28:24 -0000
@@ -960,8 +960,8 @@
     '#title' => t('Mode'),
     '#default_value' => LOCALE_IMPORT_KEEP,
     '#options' => array(
-      LOCALE_IMPORT_OVERWRITE => t('Strings in the uploaded file replace existing ones, new ones are added'),
-      LOCALE_IMPORT_KEEP => t('Existing strings are kept, only new strings are added')
+      LOCALE_IMPORT_OVERWRITE => t('Strings in the uploaded file replace existing ones, new ones are added. The plural format is updated.'),
+      LOCALE_IMPORT_KEEP => t('Existing strings and the plural format are kept, only new strings are added.')
     ),
   );
   $form['import']['submit'] = array('#type' => 'submit', '#value' => t('Import'));
Index: includes/locale.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/locale.inc,v
retrieving revision 1.241
diff -u -r1.241 locale.inc
--- includes/locale.inc	8 Jan 2010 13:32:43 -0000	1.241
+++ includes/locale.inc	8 Jan 2010 18:28:22 -0000
@@ -675,27 +675,33 @@
     case 'db-store':
       // We got header information.
       if ($value['msgid'] == '') {
-        $header = _locale_import_parse_header($value['msgstr']);
-
-        // Get the plural formula and update in database.
-        if (isset($header["Plural-Forms"]) && $p = _locale_import_parse_plural_forms($header["Plural-Forms"], $file->uri)) {
-          list($nplurals, $plural) = $p;
-          db_update('languages')
-            ->fields(array(
-              'plurals' => $nplurals,
-              'formula' => $plural,
-            ))
-            ->condition('language', $lang)
-            ->execute();
-        }
-        else {
-          db_update('languages')
-            ->fields(array(
-              'plurals' => 0,
-              'formula' => '',
-            ))
-            ->condition('language', $lang)
-            ->execute();
+        $languages = language_list();
+        if (($mode != LOCALE_IMPORT_KEEP) || empty($languages[$lang]->plurals)) {
+          // Since we only need to parse the header if we ought to update the
+          // plural formula, only run this if we don't need to keep existing 
+          // data untouched or if we don't have an existing plural formula.
+          $header = _locale_import_parse_header($value['msgstr']);
+
+          // Get the plural formula and update in database.
+          if (isset($header["Plural-Forms"]) && $p = _locale_import_parse_plural_forms($header["Plural-Forms"], $file->uri)) {
+            list($nplurals, $plural) = $p;
+            db_update('languages')
+              ->fields(array(
+                'plurals' => $nplurals,
+                'formula' => $plural,
+              ))
+              ->condition('language', $lang)
+              ->execute();
+          }
+          else {
+            db_update('languages')
+              ->fields(array(
+                'plurals' => 0,
+                'formula' => '',
+              ))
+              ->condition('language', $lang)
+              ->execute();
+          }
         }
         $header_done = TRUE;
       }
