aboutsummaryrefslogtreecommitdiffstats
path: root/process_bug.cgi
diff options
context:
space:
mode:
Diffstat (limited to 'process_bug.cgi')
-rwxr-xr-xprocess_bug.cgi8
1 files changed, 3 insertions, 5 deletions
diff --git a/process_bug.cgi b/process_bug.cgi
index 71be09168..35d41ee00 100755
--- a/process_bug.cgi
+++ b/process_bug.cgi
@@ -327,11 +327,9 @@ if ($cgi->param('product') ne $cgi->param('dontchange')) {
$product = Bugzilla::Product::check_product(scalar $cgi->param('product'));
@newprod_ids = ($product->id);
} else {
- @newprod_ids = @{$dbh->selectcol_arrayref("SELECT DISTINCT product_id
- FROM bugs
- WHERE bug_id IN (" .
- join(',', @idlist) .
- ")")};
+ @newprod_ids = @{$dbh->selectcol_arrayref(
+ "SELECT DISTINCT product_id FROM bugs WHERE "
+ . $dbh->sql_in('bug_id', \@idlist))};
if (scalar(@newprod_ids) == 1) {
$product = new Bugzilla::Product($newprod_ids[0]);
}