From e3e16d181d13924c17a255b781cce1ca9aabe7be Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Sun, 16 Jun 2013 08:04:56 -0400 Subject: [PATCH 1/5] Code has to be executed for each iteration of the loop --- libraries/sql.lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/sql.lib.php b/libraries/sql.lib.php index 56986eba83..8a9198219a 100644 --- a/libraries/sql.lib.php +++ b/libraries/sql.lib.php @@ -127,7 +127,7 @@ function getTableHtmlForMultipleQueries( $sql_query = $sql_data['valid_sql'][$sql_no]; // Parse and analyze the query - require_once 'libraries/parse_analyze.lib.php'; + require 'libraries/parse_analyze.lib.php'; $unlim_num_rows = PMA_Table::countRecords($db, $table, true); $showtable = PMA_Table::sGetStatusInfo($db, $table, null, true); From c4883127c7756018dcee296e822721c70a77f191 Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Sun, 16 Jun 2013 08:08:07 -0400 Subject: [PATCH 2/5] This file should not end in .lib.php --- import.php | 2 +- libraries/{parse_analyze.lib.php => parse_analyze.inc.php} | 0 libraries/sql.lib.php | 4 ++-- sql.php | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) rename libraries/{parse_analyze.lib.php => parse_analyze.inc.php} (100%) diff --git a/import.php b/import.php index 3c98ea3486..50cdd7b17f 100644 --- a/import.php +++ b/import.php @@ -571,7 +571,7 @@ if (isset($message)) { // (but if the query is too large, in case of an imported file, the parser // can choke on it so avoid parsing) if (strlen($sql_query) <= $GLOBALS['cfg']['MaxCharactersInDisplayedSQL']) { - include_once 'libraries/parse_analyze.lib.php'; + include_once 'libraries/parse_analyze.inc.php'; } // There was an error? diff --git a/libraries/parse_analyze.lib.php b/libraries/parse_analyze.inc.php similarity index 100% rename from libraries/parse_analyze.lib.php rename to libraries/parse_analyze.inc.php diff --git a/libraries/sql.lib.php b/libraries/sql.lib.php index 8a9198219a..56790fbdf7 100644 --- a/libraries/sql.lib.php +++ b/libraries/sql.lib.php @@ -123,11 +123,11 @@ function getTableHtmlForMultipleQueries( $tables_array ); - // for the use of the parse_analyze.lib.php + // for the use of the parse_analyze.inc.php $sql_query = $sql_data['valid_sql'][$sql_no]; // Parse and analyze the query - require 'libraries/parse_analyze.lib.php'; + require 'libraries/parse_analyze.inc.php'; $unlim_num_rows = PMA_Table::countRecords($db, $table, true); $showtable = PMA_Table::sGetStatusInfo($db, $table, null, true); diff --git a/sql.php b/sql.php index 707b5c0a46..1f0fda58b8 100644 --- a/sql.php +++ b/sql.php @@ -202,7 +202,7 @@ if (empty($sql_query) && strlen($table) && strlen($db)) { /** * Parse and analyze the query */ -require_once 'libraries/parse_analyze.lib.php'; +require_once 'libraries/parse_analyze.inc.php'; /** From b39aeb1f89120ff752c9dc3df486b0c3f441be61 Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Sun, 16 Jun 2013 08:10:16 -0400 Subject: [PATCH 3/5] Remove author name --- export.php | 4 ++-- index.php | 4 ++-- libraries/parse_analyze.inc.php | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/export.php b/export.php index 4b0039db7f..297dad6d87 100644 --- a/export.php +++ b/export.php @@ -422,8 +422,8 @@ if ($onfly_compression) { } // Some of memory is needed for other thins and as treshold. - // Nijel: During export I had allocated (see memory_get_usage function) - // approx 1.2MB so this comes from that. + // During export I had allocated (see memory_get_usage function) + // approx 1.2MB so this comes from that. if ($memory_limit > 1500000) { $memory_limit -= 1500000; } diff --git a/index.php b/index.php index 2c3ec25f6b..07acc4a247 100644 --- a/index.php +++ b/index.php @@ -405,7 +405,7 @@ if ($server != 0 } /** - * Nijel: As we try to handle charsets by ourself, mbstring overloads just + * As we try to handle charsets by ourself, mbstring overloads just * break it, see bug 1063821. */ if (@extension_loaded('mbstring') && @ini_get('mbstring.func_overload') > 1) { @@ -420,7 +420,7 @@ if (@extension_loaded('mbstring') && @ini_get('mbstring.func_overload') > 1) { } /** - * Nijel: mbstring is used for handling multibyte inside parser, so it is good + * mbstring is used for handling multibyte inside parser, so it is good * to tell user something might be broken without it, see bug #1063149. */ if (! @extension_loaded('mbstring')) { diff --git a/libraries/parse_analyze.inc.php b/libraries/parse_analyze.inc.php index d26d21579d..78f58987dc 100644 --- a/libraries/parse_analyze.inc.php +++ b/libraries/parse_analyze.inc.php @@ -96,7 +96,7 @@ if ($is_select) { } else { $db = $prev_db; } - // Nijel: don't change reload, if we already decided to reload in import + // Don't change reload, if we already decided to reload in import if (empty($reload) && empty($GLOBALS['is_ajax_request'])) { $reload = ($db == $prev_db) ? 0 : 1; } From ffaa1d211669ad0aefce0a6f1cfa726548a4c141 Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Sun, 16 Jun 2013 08:11:16 -0400 Subject: [PATCH 4/5] Fix typos --- export.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/export.php b/export.php index 297dad6d87..4838d01b94 100644 --- a/export.php +++ b/export.php @@ -421,7 +421,7 @@ if ($onfly_compression) { $memory_limit = (int)$memory_limit; } - // Some of memory is needed for other thins and as treshold. + // Some of memory is needed for other things and as threshold. // During export I had allocated (see memory_get_usage function) // approx 1.2MB so this comes from that. if ($memory_limit > 1500000) { From 32c8ac600f1e05d3401c31ff2435a85f9bc570f0 Mon Sep 17 00:00:00 2001 From: Marc Delisle Date: Sun, 16 Jun 2013 08:12:17 -0400 Subject: [PATCH 5/5] Fix typo --- libraries/sql.lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/sql.lib.php b/libraries/sql.lib.php index 56790fbdf7..6902588af8 100644 --- a/libraries/sql.lib.php +++ b/libraries/sql.lib.php @@ -91,7 +91,7 @@ function getTableHtmlForMultipleQueries( $querytime_before = array_sum(explode(' ', microtime())); // Assignment for variable is not needed since the results are - // looiping using the connection + // looping using the connection @$GLOBALS['dbi']->tryMultiQuery($multi_sql); $querytime_after = array_sum(explode(' ', microtime()));