From ff092dc12ce5916122a608aa2209cc41bfd7f25c Mon Sep 17 00:00:00 2001 From: Garvin Hicking Date: Thu, 24 Jul 2003 14:57:58 +0000 Subject: [PATCH] Bug #776016 (TRUNCATE table needs confirmation) --- ChangeLog | 4 ++++ libraries/sqlparser.lib.php3 | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 06514985b..80164b1b2 100755 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,10 @@ phpMyAdmin - Changelog $Id$ $Source$ +2003-07-24 Garvin Hicking + * libraries/sqlparser.lib.php3 - Confirmation is also needed on + TRUNCATE statements! + 2003-07-24 Marc Delisle * libraries/sqlparser.lib.php3 /relation.lib.php3 /get_foreign.lib.php3: bug 772765, InnoDB and multi-columns foreign key diff --git a/libraries/sqlparser.lib.php3 b/libraries/sqlparser.lib.php3 index acba37d4a..13b17d3cf 100644 --- a/libraries/sqlparser.lib.php3 +++ b/libraries/sqlparser.lib.php3 @@ -1209,7 +1209,8 @@ if (!defined('PMA_SQP_LIB_INCLUDED')) { // if the first reserved word is DROP or DELETE, // we know this is a query that needs to be confirmed if ($first_reserved_word=='DROP' - || $first_reserved_word == 'DELETE') { + || $first_reserved_word == 'DELETE' + || $first_reserved_word == 'TRUNCATE') { $subresult['queryflags']['need_confirm'] = 1; }