Fixed &fatal for Gecko compatibility with double '<?xml...' heading.
authorshort <>
Sun, 31 Jul 2005 00:01:30 +0000 (00:01 +0000)
committershort <>
Sun, 31 Jul 2005 00:01:30 +0000 (00:01 +0000)
Web.pm

diff --git a/Web.pm b/Web.pm
index 9268953..33324e1 100644 (file)
--- a/Web.pm
+++ b/Web.pm
@@ -296,7 +296,9 @@ my($msg)=@_;
        cluck "FATAL: $msg";
 
        $W->{"indexme"}=0;      # For the case no heading was sent yet.
-       $W->{"heading_done"}=0; # for the case of already sent {"header_only"}==1
+       # Do not send it unconditionally.
+       # The intial duplicated '<?xml...' crashes Gecko parser.
+       $W->{"heading_done"}=0 if $W->{"header_only"};
        $W->{"header_only"}=0;  # assurance for &heading
        My::Web->heading();
        Wprint "\n".vskip("3ex")."<hr /><h1 class=\"error\">FATAL ERROR: $msg!</h1>\n"