summaryrefslogtreecommitdiff
path: root/IkiWiki
diff options
context:
space:
mode:
authorJoey Hess <joey@gnu.kitenet.net>2009-03-09 13:52:51 -0400
committerJoey Hess <joey@gnu.kitenet.net>2009-03-09 13:52:51 -0400
commit793e9332c3fc6db6733dce6783d6ac9c8058bb8d (patch)
tree5ba21677756bcf80da91c636c40fc61adaf43c93 /IkiWiki
parent10872b91afce95193520f08c0e0e483d70aad96b (diff)
avoid uninitialized value warnings
Diffstat (limited to 'IkiWiki')
-rw-r--r--IkiWiki/Plugin/404.pm3
1 files changed, 2 insertions, 1 deletions
diff --git a/IkiWiki/Plugin/404.pm b/IkiWiki/Plugin/404.pm
index 5550ea7d1..bae9e15d1 100644
--- a/IkiWiki/Plugin/404.pm
+++ b/IkiWiki/Plugin/404.pm
@@ -67,7 +67,8 @@ sub cgi_page_from_404 ($$$) {
sub cgi ($) {
my $cgi=shift;
- if ($ENV{REDIRECT_STATUS} eq '404') {
+ if (exists $ENV{REDIRECT_STATUS} &&
+ $ENV{REDIRECT_STATUS} eq '404') {
my $page = cgi_page_from_404($ENV{REDIRECT_URL},
$config{url}, $config{usedirs});
IkiWiki::Plugin::goto::cgi_goto($cgi, $page);