summaryrefslogtreecommitdiff
path: root/sql/item.cc
diff options
context:
space:
mode:
authorIgor Babaev <igor@askmonty.org>2012-04-06 16:40:39 -0700
committerIgor Babaev <igor@askmonty.org>2012-04-06 16:40:39 -0700
commitc1feaf8d8a7ac15554e2db6c4b2222517447fe3d (patch)
treed812b6520c67b9ab1618c820c61ef06d474472ab /sql/item.cc
parent545377ab50c4ae7651d9b6d6882712982f6871dd (diff)
parent4ca9b8eb3af0fbfabd493bf72a0cc0e57f51d935 (diff)
downloadmariadb-git-c1feaf8d8a7ac15554e2db6c4b2222517447fe3d.tar.gz
Merge.
Diffstat (limited to 'sql/item.cc')
-rw-r--r--sql/item.cc15
1 files changed, 15 insertions, 0 deletions
diff --git a/sql/item.cc b/sql/item.cc
index 60d01c19b8c..70c5798eb6c 100644
--- a/sql/item.cc
+++ b/sql/item.cc
@@ -951,6 +951,21 @@ void Item::set_name(const char *str, uint length, CHARSET_INFO *cs)
}
+void Item::set_name_for_rollback(THD *thd, const char *str, uint length,
+ CHARSET_INFO *cs)
+{
+ char *old_name, *new_name;
+ old_name= name;
+ set_name(str, length, cs);
+ new_name= name;
+ if (old_name != new_name)
+ {
+ name= old_name;
+ thd->change_item_tree((Item **) &name, (Item *) new_name);
+ }
+}
+
+
/**
@details
This function is called when: