Index: globalredirect.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/globalredirect/globalredirect.module,v
retrieving revision 1.1.2.4.2.5.2.14
diff -u -p -r1.1.2.4.2.5.2.14 globalredirect.module
--- globalredirect.module	22 Dec 2008 10:34:32 -0000	1.1.2.4.2.5.2.14
+++ globalredirect.module	2 Oct 2009 16:32:46 -0000
@@ -37,6 +37,12 @@ function globalredirect_help($section) {
 function globalredirect_init() {
   global $language;
 
+  // Don't interfere when executed from the command line, e.g. Drush, as this
+  // would unexpectedly abort script execution.
+  if (!isset($_SERVER['SERVER_ADDR'])) {
+    return;
+  }
+
   /**
    * We need to do a test to make sure we only clean up URL's for the main request. This stops modules such as
    * the Ad Module which had its own script in its folder doing a bootstrap which invoked hook_init and caused some banners to get "cleaned up"
