Merge pull request #231 from kasunchathuranga/Bug3865

Fix bug #3865 Using like operator on each backslash needs 4 backslash pr...
This commit is contained in:
Michal Čihař 2013-04-07 03:09:11 -07:00
commit bff52d3944
2 changed files with 8 additions and 2 deletions

View File

@ -103,6 +103,7 @@ underscore
+ rfe #1319 Permit to create index when creating foreign key
- bug #3703 Incorrect updating of the list of users
- bug #3853 Blowfish implementation might be broken (replace with phpseclib)
- bug #3865 Using like operator on each backslash needs 4 backslash protection
3.5.9.0 (not yet released)

View File

@ -591,8 +591,13 @@ EOT;
. ' (' . implode(',', $values) . ')';
}
} else {
$where = $backquoted_name . ' ' . $func_type . ' ' . $quot
. PMA_Util::sqlAddSlashes($criteriaValues) . $quot;
if ($func_type == 'LIKE %...%' || $func_type == 'LIKE') {
$where = $backquoted_name . ' ' . $func_type . ' ' . $quot
. PMA_Util::sqlAddSlashes($criteriaValues, true) . $quot;
} else {
$where = $backquoted_name . ' ' . $func_type . ' ' . $quot
. PMA_Util::sqlAddSlashes($criteriaValues) . $quot;
}
}
} // end if