From: timeless%mozdev.org <> Date: Thu, 23 Jan 2003 15:43:06 +0000 (+0000) Subject: Bug 190197 AnyEntryGroups() is broken in globals.pl; call from enter_bug.cgi breaks... X-Git-Tag: bugzilla-2.17.4~102 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=551081042333edc563ebccc1a10e0b5805b51858;p=thirdparty%2Fbugzilla.git Bug 190197 AnyEntryGroups() is broken in globals.pl; call from enter_bug.cgi breaks bug entering patch by jon@vmware.com r=justdave a=justdave --- diff --git a/globals.pl b/globals.pl index 5ad624f9a8..8162b9d21f 100644 --- a/globals.pl +++ b/globals.pl @@ -474,12 +474,15 @@ sub AnyEntryGroups { $query .= " AND product_id = $product_id" if ($product_id); $query .= " LIMIT 1"; SendSQL($query); - $::CachedAnyEntryGroups{$product_id} = MoreSQLData(); - FetchSQLData(); - PopGlobalSQLState(); - return $::CachedAnyEntryGroups{$product_id}; + if (MoreSQLData()) { + $::CachedAnyEntryGroups{$product_id} = MoreSQLData(); + FetchSQLData(); + PopGlobalSQLState(); + return $::CachedAnyEntryGroups{$product_id}; + } else { + return undef; + } } - # # This function checks if there are any default groups defined. # If so, then groups may have to be changed when bugs move from