Index: common.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/common.inc,v
retrieving revision 1.756.2.79
diff -u -p -r1.756.2.79 common.inc
--- common.inc	4 Mar 2010 00:15:28 -0000	1.756.2.79
+++ common.inc	2 Jun 2010 13:40:24 -0000
@@ -164,7 +164,10 @@ function drupal_get_headers() {
 function drupal_final_markup($content) {
   // Make sure that the charset is always specified as the first element of the
   // head region to prevent encoding-based attacks.
-  return preg_replace('/<head[^>]*>/i', "\$0\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />", $content, 1);
+  if (!preg_match('/<head[^>]*>\s*<meta http-equiv="Content-Type" content="text\/html; charset=utf-8" \/>/i', $content)) {
+    $content = preg_replace('/<head[^>]*>/i', "\$0\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf-8\" />", $content, 1);
+  }
+  return $content;
 }
 
 /**
