From 35099eb6b652185b37f3066a2485cc45c49d16f9 Mon Sep 17 00:00:00 2001 From: Robin Johnson Date: Wed, 31 Jul 2002 20:18:27 +0000 Subject: [PATCH] 2002-07-31 Robin Johnson tbl_properties_structure.php3 +40: Fix for a warning notice libraries/sqlparser.lib.php3: Fix for another minor formatting quirk --- ChangeLog | 4 ++++ libraries/sqlparser.lib.php3 | 5 +++-- tbl_properties_structure.php3 | 2 +- 3 files changed, 8 insertions(+), 3 deletions(-) diff --git a/ChangeLog b/ChangeLog index 32175486a..9ffe9984c 100755 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,10 @@ phpMyAdmin - Changelog $Id$ $Source$ +2002-07-31 Robin Johnson + * tbl_properties_structure.php3 +40: Fix for a warning notice + * libraries/sqlparser.lib.php3: Fix for another minor formatting quirk + 2002-07-31 Marc Delisle * lang/thai: update, thanks to Arthit Suriyawongkul diff --git a/libraries/sqlparser.lib.php3 b/libraries/sqlparser.lib.php3 index 7b0c2be57..34f63e615 100644 --- a/libraries/sqlparser.lib.php3 +++ b/libraries/sqlparser.lib.php3 @@ -180,10 +180,10 @@ if (!defined('PMA_SQP_LIB_INCLUDED')) { // Checks for MySQL escaping using a \ // And checks for ANSI escaping using the $quotetype character - if (PMA_STR_charIsEscaped($sql, $pos)) { + if ( ($pos < $len) && PMA_STR_charIsEscaped($sql, $pos)) { $pos ++; continue; - } else if (($sql[$pos] == $quotetype) && ($sql[$pos + 1] == $quotetype)) { + } else if ( ($pos+1 < $len) && ($sql[$pos] == $quotetype) && ($sql[$pos + 1] == $quotetype)) { $pos = $pos + 2; continue; } else { @@ -553,6 +553,7 @@ if (!defined('PMA_SQP_LIB_INCLUDED')) { $keywords_with_brackets_1before = array( 'INDEX', + 'KEY', 'ON', 'USING' ); diff --git a/tbl_properties_structure.php3 b/tbl_properties_structure.php3 index 65b9578de..f8f6979b5 100755 --- a/tbl_properties_structure.php3 +++ b/tbl_properties_structure.php3 @@ -264,7 +264,7 @@ if ($fields_cnt > 20) { 20) echo "\n\n";