Index: modules/system.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/system.module,v
retrieving revision 1.216
diff -u -F^f -r1.216 system.module
--- modules/system.module	27 Jun 2005 18:33:33 -0000	1.216
+++ modules/system.module	16 Jul 2005 09:47:18 -0000
@@ -598,8 +598,6 @@ function system_site_settings($module = 
  * Menu callback; display theme configuration for entire site and individual themes.
  */
 function system_theme_settings($key = '') {
-  system_settings_save();
-
   // Default settings are defined in theme_get_settings() in includes/theme.inc
   if ($key) {
     $settings = theme_get_settings($key);
@@ -619,11 +617,8 @@ function system_theme_settings($key = ''
       $filename = ($key) ? str_replace('/', '_', $key) . '_logo.' . $parts['extension'] : 'logo.' . $parts['extension'];
 
       if ($file = file_save_upload('logo_upload', $filename, 1)) {
-        $settings['default_logo'] = 0;
-        $settings['logo_path'] = $file->filepath;
-
-        // Update the variable table with the new settings so that they take effect immediately.
-        variable_set($var, $settings);
+        $_POST['edit'][$var]['default_logo'] = 0;
+        $_POST['edit'][$var]['logo_path'] = $file->filepath;
       }
     }
     else {
@@ -637,14 +632,13 @@ function system_theme_settings($key = ''
     $filename = ($key) ? str_replace('/', '_', $key) . '_favicon.' . $parts['extension'] : 'favicon.' . $parts['extension'];
 
     if ($file = file_save_upload('favicon_upload', $filename, 1)) {
-      $settings['default_favicon'] = 0;
-      $settings['favicon_path'] = $file->filepath;
-
-      // Update the variable table with the new settings so that they take effect immediately.
-      variable_set($var, $settings);
+      $_POST['edit'][$var]['default_favicon'] = 0;
+      $_POST['edit'][$var]['favicon_path'] = $file->filepath;
     }
   }
 
+  system_settings_save();
+
   $form = '';
 
   // Logo settings
