mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
Merge bodhi.local:/opt/local/work/mysql-5.0-26750
into bodhi.local:/opt/local/work/mysql-5.1-runtime
This commit is contained in:
@@ -3674,9 +3674,6 @@ end_with_restore_list:
|
||||
clean up the environment.
|
||||
*/
|
||||
create_sp_error:
|
||||
lex->unit.cleanup();
|
||||
delete lex->sphead;
|
||||
lex->sphead= 0;
|
||||
if (sp_result != SP_OK )
|
||||
goto error;
|
||||
send_ok(thd);
|
||||
@@ -4052,9 +4049,6 @@ create_sp_error:
|
||||
/* Conditionally writes to binlog. */
|
||||
res= mysql_create_or_drop_trigger(thd, all_tables, 1);
|
||||
|
||||
/* We don't care about trigger body after this point */
|
||||
delete lex->sphead;
|
||||
lex->sphead= 0;
|
||||
break;
|
||||
}
|
||||
case SQLCOM_DROP_TRIGGER:
|
||||
@@ -5208,12 +5202,7 @@ void mysql_parse(THD *thd, char *inBuf, uint length)
|
||||
else
|
||||
#endif
|
||||
{
|
||||
if (thd->net.report_error)
|
||||
{
|
||||
delete lex->sphead;
|
||||
lex->sphead= NULL;
|
||||
}
|
||||
else
|
||||
if (! thd->net.report_error)
|
||||
{
|
||||
/*
|
||||
Binlog logs a string starting from thd->query and having length
|
||||
@@ -5233,7 +5222,6 @@ void mysql_parse(THD *thd, char *inBuf, uint length)
|
||||
query_cache_end_of_result(thd);
|
||||
}
|
||||
}
|
||||
lex->unit.cleanup();
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -5241,19 +5229,14 @@ void mysql_parse(THD *thd, char *inBuf, uint length)
|
||||
DBUG_PRINT("info",("Command aborted. Fatal_error: %d",
|
||||
thd->is_fatal_error));
|
||||
|
||||
/*
|
||||
The first thing we do after parse error is freeing sp_head to
|
||||
ensure that we have restored original memroot.
|
||||
*/
|
||||
if (lex->sphead)
|
||||
{
|
||||
/* Clean up after failed stored procedure/function */
|
||||
delete lex->sphead;
|
||||
lex->sphead= NULL;
|
||||
}
|
||||
query_cache_abort(&thd->net);
|
||||
lex->unit.cleanup();
|
||||
}
|
||||
if (thd->lex->sphead)
|
||||
{
|
||||
delete thd->lex->sphead;
|
||||
thd->lex->sphead= 0;
|
||||
}
|
||||
lex->unit.cleanup();
|
||||
thd->proc_info="freeing items";
|
||||
thd->end_statement();
|
||||
thd->cleanup_after_query();
|
||||
|
Reference in New Issue
Block a user