From 998e2f50278713fff1c52810eef4fb5fa41556f7 Mon Sep 17 00:00:00 2001 From: Jakub Vrana Date: Mon, 12 Sep 2011 21:14:22 +0200 Subject: [PATCH] Ignore whitespace after semicolon --- adminer/sql.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/adminer/sql.inc.php b/adminer/sql.inc.php index cc98e5ec..5ae86a28 100644 --- a/adminer/sql.inc.php +++ b/adminer/sql.inc.php @@ -33,7 +33,7 @@ if (!$error && $_POST) { @ini_set("memory_limit", max(ini_bytes("memory_limit"), 2 * strlen($query) + memory_get_usage() + 8e6)); // @ - may be disabled, 2 - substr and trim, 8e6 - other variables } if ($query != "" && strlen($query) < 1e6) { // don't add big queries - $q = $query . (ereg(';$', $query) ? "" : ";"); //! doesn't work with DELIMITER | + $q = $query . (ereg(";[ \t\r\n]*\$", $query) ? "" : ";"); //! doesn't work with DELIMITER | if (!$history || end($history) != $q) { // no repeated queries $history[] = $q; }