1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-13 18:14:07 +02:00

Fix long SQL query crash (bug #2839231)

Remove regular expression double repetition

git-svn-id: https://adminer.svn.sourceforge.net/svnroot/adminer/trunk@982 7c3ca157-0c34-0410-bff1-cbf682f78f5c
This commit is contained in:
jakubvrana
2009-08-19 17:10:06 +00:00
parent bd52f2a527
commit 26c9d64bfd
9 changed files with 16 additions and 14 deletions

View File

@@ -51,7 +51,7 @@ if ($_POST) {
// propose database name with limited privileges
$result = $dbh->query("SHOW GRANTS");
while ($row = $result->fetch_row()) {
if (preg_match('~ ON (`(([^\\\\`]+|``|\\\\.)*)%`\\.\\*)?~', $row[0], $match) && $match[1]) {
if (preg_match('~ ON (`(([^\\\\`]|``|\\\\.)*)%`\\.\\*)?~', $row[0], $match) && $match[1]) {
$name = stripcslashes(idf_unescape($match[2]));
break;
}