summaryrefslogtreecommitdiff
path: root/sql/sql_class.cc
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2018-01-02 21:52:46 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2018-01-02 21:52:46 +0200
commit51e4650ed0644ed88cf5d542bd0cab50e7ea0343 (patch)
treeaaf73f6a77c6c1ad03473f4d664356b6f60169c9 /sql/sql_class.cc
parenteef2bc5a5c30eef43eee035e23b87286a8dd50bd (diff)
parent20fab71b144f85be9e2ccc145d24d257b0e9df7e (diff)
downloadmariadb-git-51e4650ed0644ed88cf5d542bd0cab50e7ea0343.tar.gz
Merge 5.5 into 10.0
Diffstat (limited to 'sql/sql_class.cc')
-rw-r--r--sql/sql_class.cc9
1 files changed, 8 insertions, 1 deletions
diff --git a/sql/sql_class.cc b/sql/sql_class.cc
index eedda8579e7..1f5c465a37a 100644
--- a/sql/sql_class.cc
+++ b/sql/sql_class.cc
@@ -2394,6 +2394,8 @@ void THD::nocheck_register_item_tree_change(Item **place, Item *old_value,
MEM_ROOT *runtime_memroot)
{
Item_change_record *change;
+ DBUG_ENTER("THD::nocheck_register_item_tree_change");
+ DBUG_PRINT("enter", ("Register %p <- %p", old_value, (*place)));
/*
Now we use one node per change, which adds some memory overhead,
but still is rather fast as we use alloc_root for allocations.
@@ -2406,12 +2408,13 @@ void THD::nocheck_register_item_tree_change(Item **place, Item *old_value,
OOM, thd->fatal_error() is called by the error handler of the
memroot. Just return.
*/
- return;
+ DBUG_VOID_RETURN;
}
change= new (change_mem) Item_change_record;
change->place= place;
change->old_value= old_value;
change_list.append(change);
+ DBUG_VOID_RETURN;
}
/**
@@ -2452,7 +2455,11 @@ void THD::rollback_item_tree_changes()
DBUG_ENTER("rollback_item_tree_changes");
while ((change= it++))
+ {
+ DBUG_PRINT("info", ("revert %p -> %p",
+ change->old_value, (*change->place)));
*change->place= change->old_value;
+ }
/* We can forget about changes memory: it's allocated in runtime memroot */
change_list.empty();
DBUG_VOID_RETURN;