Index: mollom.info
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/mollom/mollom.info,v
retrieving revision 1.2.2.2
diff -u -p -r1.2.2.2 mollom.info
--- mollom.info	17 Nov 2009 17:01:49 -0000	1.2.2.2
+++ mollom.info	22 Sep 2010 12:36:09 -0000
@@ -2,3 +2,7 @@
 name = Mollom
 description = Protects forms against spam.
 core = 6.x
+
+; Support for http://drupal.org/project/module_supports
+conflicts[] = no_anon
+conflicts[] = fbconnect
Index: mollom.install
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/mollom/mollom.install,v
retrieving revision 1.2.2.33
diff -u -p -r1.2.2.33 mollom.install
--- mollom.install	12 Sep 2010 23:44:14 -0000	1.2.2.33
+++ mollom.install	22 Sep 2010 12:44:35 -0000
@@ -68,6 +68,13 @@ function mollom_requirements($phase = 'r
       $requirements['mollom']['value'] = t('Network error');
       $requirements['mollom']['description'] = t('The Mollom servers could not be contacted. Please make sure that your web server can make outgoing HTTP requests.');
     }
+    if (!$status['uid0 valid']) {
+      $requirements['mollom']['value'] = t('Database error');
+      $requirements['mollom']['description'] = t('Invalid anonymous user record. Visit the <a href="@status-url">Status report</a> to automatically correct the problem.', array(
+        '@status-url' => url('admin/reports/status'),
+      ));
+      watchdog('mollom', 'Missing record for anonymous user (uid 0) in the {users} table.', array(), WATCHDOG_EMERG);
+    }
   }
   return $requirements;
 }
Index: mollom.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/mollom/mollom.module,v
retrieving revision 1.2.2.172
diff -u -p -r1.2.2.172 mollom.module
--- mollom.module	20 Sep 2010 23:51:30 -0000	1.2.2.172
+++ mollom.module	22 Sep 2010 12:46:52 -0000
@@ -1152,6 +1152,7 @@ function _mollom_status($reset = FALSE) 
   $status = variable_get('mollom_status', array(
     'keys' => FALSE,
     'keys valid' => FALSE,
+    'uid0 valid' => TRUE,
   ));
 
   // Both API keys are required.
@@ -1162,6 +1163,12 @@ function _mollom_status($reset = FALSE) 
   // If we have keys and are asked to reset, check whether keys are valid.
   if ($status['keys'] && $reset) {
     $status['keys valid'] = mollom('mollom.verifyKey', _mollom_get_version());
+
+    // Check for a valid uid 0 record, which is required for this module.
+    // @see system_status()
+    if (!db_result(db_query_range("SELECT 1 FROM {users} WHERE uid = 0", 0, 1))) {
+      $status['uid0 valid'] = FALSE;
+    }
   }
 
   // In case of an error, indicate whether we have a non-empty server list.
