Closed Bug 398735 Opened 17 years ago Closed 17 years ago

sanitycheck.cgi hardcodes bug statuses in the everconfirmed check

Categories

(Bugzilla :: Administration, task)

3.1.2
task
Not set
normal

Tracking

()

RESOLVED FIXED
Bugzilla 3.2

People

(Reporter: LpSolit, Assigned: LpSolit)

References

Details

Attachments

(1 file)

Now that you can customize bug statuses, sanitycheck.cgi should not have the following SQL fragment hardcoded:

BugCheck("bugs WHERE bug_status IN ('NEW', 'ASSIGNED', 'REOPENED') AND everconfirmed = 0",

The reason is that this query will miss all new or renamed bug statuses, and may give false negative results.

It should look for all open bug statuses and exclude the hardcoded UNCONFIRMED state.
Summary: sanitycheck.cgi may check that everconfirmed is correctly set against wrong bug statuses → sanitycheck.cgi hardcodes bug statuses in the everconfirmed check
Attached patch patch, v1Splinter Review
Heh nice, this patch permitted me to find bugs which were indeed "unconfirmed", i.e. with everconfirmed = 0, despite the bug status was not UNCONFIRMED. :)
Attachment #283832 - Flags: review?(mkanat)
Comment on attachment 283832 [details] [diff] [review]
patch, v1

Sure, looks fine. :-) You could also have done it with placeholders instead of $dbh->quote, but it would have taken just as much code.
Attachment #283832 - Flags: review?(mkanat) → review+
Flags: approval+
Checking in sanitycheck.cgi;
/cvsroot/mozilla/webtools/bugzilla/sanitycheck.cgi,v  <--  sanitycheck.cgi
new revision: 1.135; previous revision: 1.134
done
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: