summaryrefslogtreecommitdiffstats
path: root/sanitycheck.cgi
diff options
context:
space:
mode:
authorcyeh%bluemartini.com <>2000-06-29 02:54:11 +0200
committercyeh%bluemartini.com <>2000-06-29 02:54:11 +0200
commit8dd07cc3b6f7e19f97c18e7a3acc71335507f36b (patch)
tree0c03b1bedb8638df36ca656bcb47f01ac8c8cdd9 /sanitycheck.cgi
parent72c286156f0951e8e4aecd397c662489912f4e8b (diff)
downloadbugzilla-8dd07cc3b6f7e19f97c18e7a3acc71335507f36b.tar.gz
bugzilla-8dd07cc3b6f7e19f97c18e7a3acc71335507f36b.tar.xz
fix for bug #44040 "sanitycheck.cgi dies if apostrophes in product, component, version,
or milestone". thanks to dave@intrec.com (Dave Miller) for the patch
Diffstat (limited to 'sanitycheck.cgi')
-rwxr-xr-xsanitycheck.cgi6
1 files changed, 3 insertions, 3 deletions
diff --git a/sanitycheck.cgi b/sanitycheck.cgi
index ee6d5e188..e381aaa82 100755
--- a/sanitycheck.cgi
+++ b/sanitycheck.cgi
@@ -188,7 +188,7 @@ while (@row = FetchSQLData()) {
foreach my $ref (@checklist) {
my ($product, $version) = (@$ref);
- SendSQL("select count(*) from versions where program = '$product' and value = '$version'");
+ SendSQL("select count(*) from versions where program = " . SqlQuote($product) . " and value = " . SqlQuote($version));
if (FetchOneColumn() != 1) {
Alert("Bug(s) found with invalid product/version: $product/$version");
}
@@ -206,7 +206,7 @@ while (@row = FetchSQLData()) {
foreach my $ref (@checklist) {
my ($product, $milestone) = (@$ref);
- SendSQL("SELECT count(*) FROM milestones WHERE product = '$product' AND value = '$milestone'");
+ SendSQL("SELECT count(*) FROM milestones WHERE product = " . SqlQuote($product) . " AND value = " . SqlQuote($milestone));
if(FetchOneColumn() != 1) {
Alert("Bug(s) found with invalud product/milestone: $product/$milestone");
}
@@ -225,7 +225,7 @@ while (@row = FetchSQLData()) {
foreach my $ref (@checklist) {
my ($product, $component) = (@$ref);
- SendSQL("select count(*) from components where program = '$product' and value = '$component'");
+ SendSQL("select count(*) from components where program = " . SqlQuote($product) . " and value = " . SqlQuote($component));
if (FetchOneColumn() != 1) {
Alert("Bug(s) found with invalid product/component: $product/$component");
}