fix error message display
authorJoey Hess <joey@gnu.kitenet.net>
Sun, 16 Aug 2009 17:43:31 +0000 (13:43 -0400)
committerJoey Hess <joey@gnu.kitenet.net>
Sun, 16 Aug 2009 17:43:31 +0000 (13:43 -0400)
The gettext call can clear $@ in at least some cases.

IkiWiki.pm

index b47da966ed548f03a1ca2c03031fcd8cc084be15..bac48c9a409ecbc0af863d58dbdcede06b89c265 100644 (file)
@@ -1255,9 +1255,10 @@ sub preprocess ($$$;$$) {
                                        );
                                };
                                if ($@) {
                                        );
                                };
                                if ($@) {
-                                       chomp $@;
+                                       my $error=$@;
+                                       chomp $error;
                                        $ret="[[!$command <span class=\"error\">".
                                        $ret="[[!$command <span class=\"error\">".
-                                               gettext("Error").": $@"."</span>]]";
+                                               gettext("Error").": $error"."</span>]]";
                                }
                        }
                        else {
                                }
                        }
                        else {