]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 254347: Use of uninitialized value msg in query.cgi
authormkanat%kerio.com <>
Sat, 19 Feb 2005 01:34:19 +0000 (01:34 +0000)
committermkanat%kerio.com <>
Sat, 19 Feb 2005 01:34:19 +0000 (01:34 +0000)
Patch By Frederic Buclin <LpSolit@gmail.com>, r=mkanat, a=justdave

query.cgi

index 2806cdd242b95e0516e249c359dddf3eb532043d..065709c2f39cd8dc0afa498457193f0e41c151f1 100755 (executable)
--- a/query.cgi
+++ b/query.cgi
@@ -443,7 +443,7 @@ if (!($cgi->param('query_format') || $cgi->param('format'))) {
 
 # Set cookie to current format as default, but only if the format
 # one that we should remember.
-if (IsValidQueryType($vars->{'format'})) {
+if (defined($vars->{'format'}) && IsValidQueryType($vars->{'format'})) {
     $cgi->send_cookie(-name => 'DEFAULTFORMAT',
                       -value => $vars->{'format'},
                       -expires => "Fri, 01-Jan-2038 00:00:00 GMT");