From: gerv%gerv.net <> Date: Mon, 7 Oct 2002 13:44:06 +0000 (+0000) Subject: Bug 172740 - "use of uninitialized variable" warnings. Patch by gerv; r=bbaetz. X-Git-Tag: bugzilla-2.17.1~79 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c84c1809b5bda16318a5dad7be9440a1be4a5fc0;p=thirdparty%2Fbugzilla.git Bug 172740 - "use of uninitialized variable" warnings. Patch by gerv; r=bbaetz. --- diff --git a/buglist.cgi b/buglist.cgi index 8c8f520084..4e1a8eec45 100755 --- a/buglist.cgi +++ b/buglist.cgi @@ -83,7 +83,7 @@ else { } # Hack to support legacy applications that think the RDF ctype is at format=rdf. -if ($::FORM{'format'} eq "rdf" && !$::FORM{'ctype'}) { +if ($::FORM{'format'} && $::FORM{'format'} eq "rdf" && !$::FORM{'ctype'}) { $::FORM{'ctype'} = "rdf"; delete($::FORM{'format'}); } diff --git a/globals.pl b/globals.pl index f1e8f0d74b..b52161eebd 100644 --- a/globals.pl +++ b/globals.pl @@ -1631,6 +1631,7 @@ sub GetFormat { my ($template, $format, $ctype) = @_; $ctype ||= "html"; + $format ||= ""; # Security - allow letters and a hyphen only $ctype =~ s/[^a-zA-Z\-]//g;