Commit f67f57a7 authored by jocuri%softhome.net's avatar jocuri%softhome.net

Patch for bug 246328: make editmilestone check for invalid sortkeys; patch by…

Patch for bug 246328: make editmilestone check for invalid sortkeys; patch by Byron Jones (glob) <bugzilla@glob.com.au>; r=vladd; a=justdave.
parent 0bd25a01
......@@ -519,6 +519,12 @@ if ($action eq 'update') {
products WRITE");
if ($sortkey != $sortkeyold) {
if (!detaint_natural($sortkey)) {
print "The sortkey for a milestone must be a number. Please press\n";
print "<b>Back</b> and try again.\n";
PutTrailer($localtrailer);
exit;
}
SendSQL("UPDATE milestones SET sortkey=$sortkey
WHERE product_id=" . $product_id . "
AND value=" . SqlQuote($milestoneold));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment