List:Internals« Previous MessageNext Message »
From:konstantin Date:November 18 2005 9:43pm
Subject:bk commit into 5.0 tree (konstantin:1.1978) BUG#13510
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of kostja. When kostja 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.1978 05/11/19 00:42:41 konstantin@stripped +3 -0
  Bug#13510 "Setting password local variable changes current 
  password": additional fix, also make sure that a syntax error is 
  returned for set names="foo" when there is no such variable or no
  stored procedure.

  sql/sql_yacc.yy
    1.442 05/11/19 00:42:22 konstantin@stripped +3 -0
    Bug#13510: fix the case when there is no stored procedure or
    no 'names' variable declared. Return a syntax error in this case.

  mysql-test/t/sp-error.test
    1.96 05/11/19 00:42:21 konstantin@stripped +3 -0
    A new test for Bug#13510 (set names out of an SP)

  mysql-test/r/sp-error.result
    1.92 05/11/19 00:42:21 konstantin@stripped +2 -0
    Test results fixed: a new test for Bug#13510

# 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:	konstantin
# Host:	dragonfly.local
# Root:	/opt/local/work/mysql-5.0-8568

--- 1.441/sql/sql_yacc.yy	2005-11-16 15:08:54 +03:00
+++ 1.442/sql/sql_yacc.yy	2005-11-19 00:42:22 +03:00
@@ -7925,6 +7925,9 @@
 	    names.length= 5;
 	    if (spc && spc->find_pvar(&names))
               my_error(ER_SP_BAD_VAR_SHADOW, MYF(0), names.str);
+            else
+              yyerror(ER(ER_SYNTAX_ERROR));
+
 	    YYABORT;
 	  }
 	| NAMES_SYM charset_name_or_default opt_collate

--- 1.91/mysql-test/r/sp-error.result	2005-11-17 03:51:07 +03:00
+++ 1.92/mysql-test/r/sp-error.result	2005-11-19 00:42:21 +03:00
@@ -845,6 +845,8 @@
 select password;
 end|
 ERROR 42000: Variable 'password' must be quoted with `...`, or renamed
+set names='foo2'|
+ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1
 create procedure bug13510_2()
 begin
 declare names varchar(10);

--- 1.95/mysql-test/t/sp-error.test	2005-11-17 03:51:07 +03:00
+++ 1.96/mysql-test/t/sp-error.test	2005-11-19 00:42:21 +03:00
@@ -1233,6 +1233,9 @@
   select password;
 end|
 
+--error ER_PARSE_ERROR
+set names='foo2'|
+
 --error ER_SP_BAD_VAR_SHADOW
 create procedure bug13510_2()
 begin
Thread
bk commit into 5.0 tree (konstantin:1.1978) BUG#13510konstantin18 Nov