summaryrefslogtreecommitdiff
path: root/sql/item_func.h
diff options
context:
space:
mode:
authorGeorgi Kodinov <kgeorge@mysql.com>2008-10-09 18:03:23 +0300
committerGeorgi Kodinov <kgeorge@mysql.com>2008-10-09 18:03:23 +0300
commit9f31df646fd28b5ed9d9891ef8c598f0c303fdd3 (patch)
treedf7c9426a25cf1ac5a2c54de96ab3d5cd949ece5 /sql/item_func.h
parent835cbfd34896ad1175fa0e71b7e40e4a8f30fef5 (diff)
downloadmariadb-git-9f31df646fd28b5ed9d9891ef8c598f0c303fdd3.tar.gz
Bug #32124 addendum
Fixed the handling of system variable retrieval in prepared statements : added a cleanup method that clears up the cache and restores the original scope of the variable (which is overwritten at fix_fields()). sql/item_func.cc: ug #32124: - preserve the requested variable scope - clean up the cache and restore the variable scope for prepared statements. sql/item_func.h: Bug #32124: preserve the requested variable scope
Diffstat (limited to 'sql/item_func.h')
-rw-r--r--sql/item_func.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/sql/item_func.h b/sql/item_func.h
index 778ffd5757f..08906ae826e 100644
--- a/sql/item_func.h
+++ b/sql/item_func.h
@@ -1433,7 +1433,7 @@ public:
class Item_func_get_system_var :public Item_func
{
sys_var *var;
- enum_var_type var_type;
+ enum_var_type var_type, orig_var_type;
LEX_STRING component;
longlong cached_llval;
double cached_dval;
@@ -1468,6 +1468,8 @@ public:
*/
bool is_written_to_binlog();
bool eq(const Item *item, bool binary_cmp) const;
+
+ void cleanup();
};