mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
Fixes after merge with 4.1
FOUND is not a reserved keyword anymore Added Item_field::set_no_const_sub() to be able to mark fields that can't be substituted Added 'simple_select' method to be able to quickly determinate if a select_result is a normal SELECT Note that the 5.0 tree is not yet up to date: Sanja will have to fix multi-update-locks for this merge to be complete
This commit is contained in:
@@ -165,6 +165,9 @@ THD::THD()
|
||||
in_lock_tables(0), bootstrap(0), spcont(NULL)
|
||||
{
|
||||
current_arena= this;
|
||||
#ifndef DBUG_OFF
|
||||
backup_arena= 0;
|
||||
#endif
|
||||
host= user= priv_user= db= ip= 0;
|
||||
catalog= (char*)"std"; // the only catalog we have for now
|
||||
host_or_ip= "connecting host";
|
||||
@@ -795,10 +798,13 @@ void THD::rollback_item_tree_changes()
|
||||
{
|
||||
I_List_iterator<Item_change_record> it(change_list);
|
||||
Item_change_record *change;
|
||||
DBUG_ENTER("rollback_item_tree_changes");
|
||||
|
||||
while ((change= it++))
|
||||
*change->place= change->old_value;
|
||||
/* We can forget about changes memory: it's allocated in runtime memroot */
|
||||
change_list.empty();
|
||||
DBUG_VOID_RETURN;
|
||||
}
|
||||
|
||||
|
||||
@@ -1585,16 +1591,24 @@ void THD::end_statement()
|
||||
void Item_arena::set_n_backup_item_arena(Item_arena *set, Item_arena *backup)
|
||||
{
|
||||
DBUG_ENTER("Item_arena::set_n_backup_item_arena");
|
||||
DBUG_ASSERT(backup_arena == 0);
|
||||
backup->set_item_arena(this);
|
||||
set_item_arena(set);
|
||||
#ifndef DBUG_OFF
|
||||
backup_arena= 1;
|
||||
#endif
|
||||
DBUG_VOID_RETURN;
|
||||
}
|
||||
|
||||
|
||||
void Item_arena::restore_backup_item_arena(Item_arena *set, Item_arena *backup)
|
||||
{
|
||||
DBUG_ENTER("Item_arena::restore_backup_item_arena");
|
||||
set->set_item_arena(this);
|
||||
set_item_arena(backup);
|
||||
#ifndef DBUG_OFF
|
||||
backup_arena= 0;
|
||||
#endif
|
||||
#ifdef NOT_NEEDED_NOW
|
||||
/*
|
||||
Reset backup mem_root to avoid its freeing.
|
||||
@@ -1605,6 +1619,7 @@ void Item_arena::restore_backup_item_arena(Item_arena *set, Item_arena *backup)
|
||||
*/
|
||||
clear_alloc_root(&backup->mem_root);
|
||||
#endif
|
||||
DBUG_VOID_RETURN;
|
||||
}
|
||||
|
||||
void Item_arena::set_item_arena(Item_arena *set)
|
||||
|
||||
Reference in New Issue
Block a user