CGI.pm detects mod_perl and calls appropriate exit (Registry's override doesn't
authorivan <ivan>
Tue, 11 Apr 2000 00:06:27 +0000 (00:06 +0000)
committerivan <ivan>
Tue, 11 Apr 2000 00:06:27 +0000 (00:06 +0000)
work here)

FS/FS/CGI.pm

index 47c034e..1e8fca6 100644 (file)
@@ -123,9 +123,14 @@ Sends headers and an HTML error message, then exits.
 sub eidiot {
   #warn "eidiot depriciated";
   idiot(@_);
-  #exit;
-  use Apache;
-  Apache::exit;
+  if (exists $ENV{MOD_PERL}) {
+    eval {
+      use Apache;
+      Apache::exit();
+    };
+  } else {
+    exit;
+  }
 }
 
 =item popurl LEVEL