diff options
author | lpsolit%gmail.com <> | 2005-08-03 09:17:45 +0200 |
---|---|---|
committer | lpsolit%gmail.com <> | 2005-08-03 09:17:45 +0200 |
commit | a1f68bd592b3a5875dc5512691238f6d3468cd26 (patch) | |
tree | ca379aee6fe09077bfd940947018e9c337cba1ba | |
parent | 1da7e6adb007e9b34d599e958c1d09cf4ea57d16 (diff) | |
download | bugzilla-a1f68bd592b3a5875dc5512691238f6d3468cd26.tar.gz bugzilla-a1f68bd592b3a5875dc5512691238f6d3468cd26.tar.xz |
Bug 303147: Bugzilla crashes when submitting a bug in the UNCONFIRMED state using PostgreSQL - Patch by Frédéric Buclin <LpSolit@gmail.com> r=mkanat a=justdave
-rwxr-xr-x | post_bug.cgi | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/post_bug.cgi b/post_bug.cgi index f6db24943..01c0e1845 100755 --- a/post_bug.cgi +++ b/post_bug.cgi @@ -139,7 +139,7 @@ if (!UserInGroup("editbugs") || $cgi->param('assigned_to') eq "") { my @bug_fields = ("version", "rep_platform", "bug_severity", "priority", "op_sys", "assigned_to", - "bug_status", "bug_file_loc", "short_desc", + "bug_status", "everconfirmed", "bug_file_loc", "short_desc", "target_milestone", "status_whiteboard"); if (Param("usebugaliases")) { @@ -208,6 +208,9 @@ check_form_field_defined($cgi, 'assigned_to'); check_form_field_defined($cgi, 'bug_file_loc'); check_form_field_defined($cgi, 'comment'); +my $everconfirmed = ($cgi->param('bug_status') eq 'UNCONFIRMED') ? 0 : 1; +$cgi->param(-name => 'everconfirmed', -value => $everconfirmed); + my @used_fields; foreach my $field (@bug_fields) { if (defined $cgi->param($field)) { @@ -215,13 +218,6 @@ foreach my $field (@bug_fields) { } } -if (defined $cgi->param('bug_status') - && $cgi->param('bug_status') ne 'UNCONFIRMED') -{ - push(@used_fields, "everconfirmed"); - $cgi->param(-name => 'everconfirmed', -value => 1); -} - $cgi->param(-name => 'product_id', -value => $product_id); push(@used_fields, "product_id"); $cgi->param(-name => 'component_id', -value => $component_id); |