List:Commits« Previous MessageNext Message »
From:ahristov Date:March 16 2006 1:20pm
Subject:bk commit into 5.1 tree (andrey:1.2191)
View as plain text  
Below is the list of changes that have just been committed into a local
5.1 repository of andrey. When andrey 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.2191 06/03/16 13:20:34 andrey@lmy004. +2 -0
  Merge ahristov@stripped:/home/bk/mysql-5.1-new
  into lmy004.:/work/mysql-5.1-bug14356

  sql/sql_yacc.yy
    1.482 06/03/16 13:20:31 andrey@lmy004. +0 -0
    Auto merged

  sql/sql_parse.cc
    1.530 06/03/16 13:20:31 andrey@lmy004. +0 -0
    Auto merged

# 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:	andrey
# Host:	lmy004.
# Root:	/work/mysql-5.1-bug14356/RESYNC

--- 1.529/sql/sql_parse.cc	2006-03-16 12:21:08 +01:00
+++ 1.530/sql/sql_parse.cc	2006-03-16 13:20:31 +01:00
@@ -3803,10 +3803,14 @@ end_with_restore_list:
         send_ok(thd, rows_affected);
 
       /* lex->unit.cleanup() is called outside, no need to call it here */
-    } while (0);  
-    lex->et->free_sphead_on_delete= true;
-    delete lex->et;
-    lex->et= 0;
+    } while (0);
+    if (!thd->spcont)
+    {
+      lex->et->free_sphead_on_delete= true;
+      lex->et->free_sp();
+      lex->et->deinit_mutexes();
+    }
+    
     break;
   }
   case SQLCOM_SHOW_CREATE_EVENT:
@@ -5845,7 +5849,9 @@ void mysql_parse(THD *thd, char *inBuf, 
           if (thd->lex->et)
           {
             thd->lex->et->free_sphead_on_delete= true;
-            delete thd->lex->et;
+            /* alloced on thd->mem_root so no real memory free but dtor call */
+            thd->lex->et->free_sp();
+            thd->lex->et->deinit_mutexes();
             thd->lex->et= NULL;
           }
 	}
@@ -5886,7 +5892,8 @@ void mysql_parse(THD *thd, char *inBuf, 
       if (thd->lex->et)
       {
         thd->lex->et->free_sphead_on_delete= true;
-        delete thd->lex->et;
+        lex->et->free_sp();
+        lex->et->deinit_mutexes();
         thd->lex->et= NULL;
       }
     }

--- 1.481/sql/sql_yacc.yy	2006-03-16 12:21:08 +01:00
+++ 1.482/sql/sql_yacc.yy	2006-03-16 13:20:31 +01:00
@@ -1275,7 +1275,7 @@ create:
 
             lex->create_info.options= $3;
 
-            if (!(lex->et= new Event_timed())) // implicitly calls Event_timed::init()
+            if (!(lex->et= new(YYTHD->mem_root) Event_timed())) // implicitly calls
Event_timed::init()
               YYABORT;
 
             /*
@@ -4813,7 +4813,7 @@ alter:
             }
             lex->spname= 0;//defensive programming
 
-            if (!(et= new Event_timed()))// implicitly calls Event_timed::init()
+            if (!(et= new (YYTHD->mem_root) Event_timed()))// implicitly calls
Event_timed::init()
               YYABORT;
             lex->et = et;
 
@@ -7717,7 +7717,7 @@ drop:
               YYABORT;
             }
 
-            if (!(lex->et= new Event_timed()))
+            if (!(lex->et= new (YYTHD->mem_root) Event_timed()))
               YYABORT;
 	  
             if (!lex->et_compile_phase)
@@ -8441,7 +8441,7 @@ show_param:
           {
             Lex->sql_command = SQLCOM_SHOW_CREATE_EVENT;
             Lex->spname= $3;
-            Lex->et= new Event_timed();
+            Lex->et= new (YYTHD->mem_root) Event_timed();
             if (!Lex->et)
               YYABORT;
             Lex->et->init_definer(YYTHD);
Thread
bk commit into 5.1 tree (andrey:1.2191)ahristov16 Mar