summaryrefslogtreecommitdiffstats
path: root/sanitycheck.cgi
diff options
context:
space:
mode:
authorterry%netscape.com <>1999-03-12 01:30:51 +0100
committerterry%netscape.com <>1999-03-12 01:30:51 +0100
commit6f3e5c8018709ef5a43427c5259e24372eefe7c3 (patch)
treeb2cbd1c250a035299e5bde3402aa1a0aa26b6492 /sanitycheck.cgi
parent5b2ed378cc135b0f3b94d960824c65e43365e247 (diff)
downloadbugzilla-6f3e5c8018709ef5a43427c5259e24372eefe7c3.tar.gz
bugzilla-6f3e5c8018709ef5a43427c5259e24372eefe7c3.tar.xz
Added 'groups' stuff, where we have different group bits that we can
put on a person or on a bug. Some of the group bits control access to bugzilla features. And a person can't access a bug unless he has every group bit set that is also set on the bug.
Diffstat (limited to 'sanitycheck.cgi')
-rwxr-xr-xsanitycheck.cgi16
1 files changed, 16 insertions, 0 deletions
diff --git a/sanitycheck.cgi b/sanitycheck.cgi
index 0d2f4072f..969cfd3c4 100755
--- a/sanitycheck.cgi
+++ b/sanitycheck.cgi
@@ -53,6 +53,22 @@ print "OK, now running sanity checks.<P>\n";
my @row;
my @checklist;
+Status("Checking groups");
+SendSQL("select bit from groups where bit != pow(2, round(log(bit) / log(2)))");
+while (my $bit = FetchOneColumn()) {
+ Alert("Illegal bit number found in group table: $bit");
+}
+
+SendSQL("select sum(bit) from groups where isbuggroup != 0");
+my $buggroupset = FetchOneColumn();
+SendSQL("select bug_id, groupset from bugs where groupset & $buggroupset != groupset");
+while (@row = FetchSQLData()) {
+ Alert("Bad groupset $row[1] found in bug " . BugLink($row[0]));
+}
+
+
+
+
Status("Checking version/products");
SendSQL("select distinct product, version from bugs");