diff options
-rwxr-xr-x | ChangeLog | 4 | ||||
-rw-r--r-- | read_dump.php | 2 |
2 files changed, 5 insertions, 1 deletions
@@ -5,6 +5,10 @@ phpMyAdmin - Changelog $Id$ $Source$ +2004-08-19 Michal Čihař <michal@cihar.com> + * read_dump.php: Fixed one case of reload detection (I forgot to update + second regexp on 2004-08-16) (bug #1011479). + 2004-08-17 Michal Čihař <michal@cihar.com> * sql.php: Work with $display_query only if set (Marc spotted this out). * libraries/display_export.lib.php: No options text should not be bold red diff --git a/read_dump.php b/read_dump.php index ad3364ba88..a1bd251f8b 100644 --- a/read_dump.php +++ b/read_dump.php @@ -312,7 +312,7 @@ if ($sql_query != '') { } // .*? bellow is non greedy expansion, just in case somebody wants to understand it... - if (!isset($reload) && preg_match('@^((-- |#)^[\n]*|/\*.*?\*/)*(DROP|CREATE)[[:space:]]+(IF EXISTS[[:space:]]+)?(TABLE|DATABASE)[[:space:]]+(.+)@i', $a_sql_query)) { + if (!isset($reload) && preg_match('@^((-- |#)[^\n]*\n|/\*.*?\*/)*(DROP|CREATE)[[:space:]]+(IF EXISTS[[:space:]]+)?(TABLE|DATABASE)[[:space:]]+(.+)@i', $sql_query)) { $reload = 1; } } // end for |