Index: includes/theme.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/theme.inc,v
retrieving revision 1.415.2.12
diff -u -p -r1.415.2.12 theme.inc
--- includes/theme.inc	17 Sep 2008 08:57:23 -0000	1.415.2.12
+++ includes/theme.inc	22 Oct 2008 22:25:39 -0000
@@ -355,6 +355,24 @@ function _theme_process_registry(&$cache
       $result[$hook]['preprocess functions'] = $info['preprocess functions'];
     }
 
+    // Let themes have preprocess functions even if they didn't register a template.
+    if ($type == 'theme' || $type == 'base_theme') {
+      foreach ($cache as $hook => $info) {
+        // Check only if it's a template and not registered by the theme or engine
+        if (!empty($info['template']) && empty($result[$hook])) {
+          if (!isset($info['preprocess functions'])) {
+            $cache[$hook]['preprocess functions'] = array();
+          }
+          if (function_exists($name . '_preprocess')) {
+            $cache[$hook]['preprocess functions'][] = $name . '_preprocess';
+          }
+          if (function_exists($name . '_preprocess_' . $hook)) {
+            $cache[$hook]['preprocess functions'][] = $name . '_preprocess_' . $hook;
+          }
+        }
+      }
+    }
+
     // Merge the newly created theme hooks into the existing cache.
     $cache = array_merge($cache, $result);
   }
