Index: includes/common.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/common.inc,v
retrieving revision 1.1097
diff -u -p -r1.1097 common.inc
--- includes/common.inc	1 Feb 2010 07:06:14 -0000	1.1097
+++ includes/common.inc	2 Feb 2010 13:50:57 -0000
@@ -5522,6 +5522,9 @@ function drupal_common_theme() {
     'image' => array(
       'variables' => array('path' => NULL, 'alt' => '', 'title' => '', 'attributes' => array(), 'getsize' => TRUE),
     ),
+    'head_title' => array(
+      'variables' => array('title' => NULL, 'name' => NULL, 'slogan' => NULL),
+    ),
     'breadcrumb' => array(
       'variables' => array('breadcrumb' => NULL),
     ),
Index: includes/theme.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/theme.inc,v
retrieving revision 1.572
diff -u -p -r1.572 theme.inc
--- includes/theme.inc	30 Jan 2010 07:54:01 -0000	1.572
+++ includes/theme.inc	2 Feb 2010 13:51:02 -0000
@@ -1561,6 +1561,19 @@ function theme_image($variables) {
 }
 
 /**
+ * Return a themed head title.
+ *
+ * @param $variables
+ *   An associative array containing:
+ *   - title : The page title.
+ *   - name : The site name.
+ *   - slogan : The site slogan.
+ */
+function theme_head_title($variables) {
+  return implode(' | ', array_filter($variables));
+}
+
+/**
  * Return a themed breadcrumb trail.
  *
  * @param $variables
@@ -2328,15 +2341,11 @@ function template_preprocess_html(&$vari
 
   // Construct page title.
   if (drupal_get_title()) {
-    $head_title = array(strip_tags(drupal_get_title()), variable_get('site_name', 'Drupal'));
+    $variables['head_title'] = theme('head_title', array('title' => strip_tags(drupal_get_title()), 'name' => variable_get('site_name', 'Drupal')));
   }
   else {
-    $head_title = array(variable_get('site_name', 'Drupal'));
-    if (variable_get('site_slogan', '')) {
-      $head_title[] = variable_get('site_slogan', '');
-    }
+    $variables['head_title'] = theme('head_title', array('name' => variable_get('site_name', 'Drupal'), 'slogan' => variable_get('site_slogan', ''));
   }
-  $variables['head_title'] = implode(' | ', $head_title);
 
   // Populate the page template suggestions.
   if ($suggestions = theme_get_suggestions(arg(), 'html')) {
