Below is the list of changes that have just been committed into a local
5.0 repository of msvensson. When msvensson does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet
1.1964 05/09/06 12:33:36 msvensson@neptunus.(none) +4 -0
Detect comment with command using extra delimiter
mysql-test/t/mysqltest.test
1.16 05/09/06 12:33:31 msvensson@neptunus.(none) +3 -1
Add test to detect "comment with command" with extra ; delimiter
Fix extra ; delimiter
mysql-test/r/mysqltest.result
1.12 05/09/06 12:33:31 msvensson@neptunus.(none) +1 -0
Update test results
mysql-test/include/have_lowercase0.inc
1.2 05/09/06 12:33:31 msvensson@neptunus.(none) +2 -2
Remove extra ; at end of command(causing it to be skipped)
client/mysqltest.c
1.156 05/09/06 12:33:31 msvensson@neptunus.(none) +16 -0
Detect comment with command using extra delimiter
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: msvensson
# Host: neptunus.(none)
# Root: /home/msvensson/mysql/mysql-5.0
--- 1.1/mysql-test/include/have_lowercase0.inc 2005-08-18 20:47:53 +02:00
+++ 1.2/mysql-test/include/have_lowercase0.inc 2005-09-06 12:33:31 +02:00
@@ -1,4 +1,4 @@
--require r/lowercase0.require
---disable_query_log;
+--disable_query_log
show variables like "lower_case_%";
---enable_query_log;
+--enable_query_log
--- 1.11/mysql-test/r/mysqltest.result 2005-09-05 22:42:30 +02:00
+++ 1.12/mysql-test/r/mysqltest.result 2005-09-06 12:33:31 +02:00
@@ -152,6 +152,7 @@
mysqltest: At line 1: End of line junk detected: "6"
mysqltest: At line 1: Missing delimiter
mysqltest: At line 1: Extra delimiter ";" found
+mysqltest: At line 1: Extra delimiter ";" found
MySQL
"MySQL"
MySQL: The world''s most popular open source database
--- 1.15/mysql-test/t/mysqltest.test 2005-09-06 09:44:20 +02:00
+++ 1.16/mysql-test/t/mysqltest.test 2005-09-06 12:33:31 +02:00
@@ -369,6 +369,8 @@
#
--error 1
--exec echo "--sleep 4;" | $MYSQL_TEST 2>&1
+--error 1
+--exec echo "--disable_query_log;" | $MYSQL_TEST 2>&1
# Allow trailing # comment
@@ -592,7 +594,7 @@
--source var/tmp/sourced1.sql
dec $num;
}
---enable_abort_on_error;
+--enable_abort_on_error
--enable_query_log
# ----------------------------------------------------------------------------
--- 1.155/client/mysqltest.c 2005-09-05 22:42:30 +02:00
+++ 1.156/client/mysqltest.c 2005-09-06 12:33:31 +02:00
@@ -3901,6 +3901,22 @@
q->type != Q_DISABLE_PARSING)
q->type= Q_COMMENT;
}
+ else if (q->type == Q_COMMENT_WITH_COMMAND &&
+ q->query[q->first_word_len-1] == ';')
+ {
+ /*
+ Detect comment with command using extra delimiter
+ Ex --disable_query_log;
+ ^ Extra delimiter causing the command
+ to be skipped
+ */
+ save= q->query[q->first_word_len-1];
+ q->query[q->first_word_len-1]= 0;
+ type= find_type(q->query, &command_typelib, 1+2);
+ q->query[q->first_word_len-1]= save;
+ if (type > 0)
+ die("Extra delimiter \";\" found");
+ }
DBUG_VOID_RETURN;
}
| Thread |
|---|
| • bk commit into 5.0 tree (msvensson:1.1964) | msvensson | 6 Sep |