List:Internals« Previous MessageNext Message »
From:sinisa Date:February 3 2004 2:22pm
Subject:bk commit into 5.0 tree (Sinisa:1.1654)
View as plain text  
Below is the list of changes that have just been committed into a local
5.0 repository of Sinisa. When Sinisa 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://www.mysql.com/doc/I/n/Installing_source_tree.html

ChangeSet
  1.1654 04/02/03 16:22:43 Sinisa@stripped +2 -0
  sp.test:
    test case for the fix for bug #2614
  sp_head.cc:
    A fix for a crashing bug in stored procedures with INSERT ... SELECT ... (Bug #2514)

  mysql-test/t/sp.test
    1.49 04/02/03 16:16:42 Sinisa@stripped +14 -1
    test case for the fix for bug #2614

  sql/sp_head.cc
    1.65 04/02/03 16:03:05 Sinisa@stripped +5 -5
    A fix for a crashing bug in stored procedures with INSERT ... SELECT ... (Bug #2514)

# 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:	Sinisa
# Host:	sinisa.nasamreza.org
# Root:	/mnt/work/petica

--- 1.48/mysql-test/t/sp.test	Wed Jan 21 15:28:33 2004
+++ 1.49/mysql-test/t/sp.test	Tue Feb  3 16:16:42 2004
@@ -1299,7 +1299,20 @@
 --replace_column 4 '0000-00-00 00:00:00' 5 '0000-00-00 00:00:00'
 show procedure status like 'bar'|
 drop procedure bar|
-
 delimiter ;|
 drop table t1;
 drop table t2;
+delimiter |
+drop procedure if exists  crash|
+create procedure crash()
+ begin
+    drop table if exists t1;
+    create table t1 (id int default '0' not null);
+    insert into t1 select 12;
+    insert into t1 select * from t1;
+ end|
+delimiter ;
+call crash();
+call crash();
+drop table t1;
+drop procedure if exists  crash;

--- 1.64/sql/sp_head.cc	Mon Jan 26 16:17:32 2004
+++ 1.65/sql/sp_head.cc	Tue Feb  3 16:03:05 2004
@@ -852,17 +852,17 @@
   {
     TABLE_LIST *tabs;
 
+    if (lex->sql_command == SQLCOM_CREATE_TABLE ||
+	lex->sql_command == SQLCOM_INSERT_SELECT)
+    {				// Restore sl->table_list.first
+      sl->table_list.first= sl->table_list_first_copy;
+    }
     // We have closed all tables, get rid of pointers to them
     for (tabs=(TABLE_LIST *)sl->table_list.first ;
 	 tabs ;
 	 tabs= tabs->next)
     {
       tabs->table= NULL;
-    }
-    if (lex->sql_command == SQLCOM_CREATE_TABLE ||
-	lex->sql_command == SQLCOM_INSERT_SELECT)
-    {				// Restore sl->table_list.first
-      sl->table_list.first= sl->table_list_first_copy;
     }
     for (ORDER *order= (ORDER *)sl->order_list.first ;
 	 order ;
Thread
bk commit into 5.0 tree (Sinisa:1.1654)sinisa3 Feb