]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 163890: editusers.cgi incorrectly treats "_" (underscore) as a wildcard
authorSunil Joshi <joshi_sunil@in.com>
Sun, 14 Oct 2012 18:03:17 +0000 (20:03 +0200)
committerFrédéric Buclin <LpSolit@gmail.com>
Sun, 14 Oct 2012 18:03:17 +0000 (20:03 +0200)
r/a=LpSolit

editusers.cgi

index 30a747ded2a4e96da67752dc8dd516414705bdd2..12f7a548d9fd310e20dd45fe546e120a82ee614b 100755 (executable)
@@ -146,8 +146,7 @@ if ($action eq 'search') {
             } elsif ($matchtype eq 'exact') {
                 $query .= $expr . ' = ?';
             } else { # substr or unknown
-                $query .= $dbh->sql_istrcmp($expr, '?', 'LIKE');
-                $matchstr = "%$matchstr%";
+                $query .= $dbh->sql_iposition('?', $expr) . ' > 0';
             }
             $nextCondition = 'AND';
             push(@bindValues, $matchstr);