diff options
Diffstat (limited to 'sql/item_inetfunc.h')
-rw-r--r-- | sql/item_inetfunc.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/sql/item_inetfunc.h b/sql/item_inetfunc.h index f19749df0af..670dce3da9f 100644 --- a/sql/item_inetfunc.h +++ b/sql/item_inetfunc.h @@ -30,12 +30,13 @@ public: Item_func_inet_aton(THD *thd, Item *a): Item_int_func(thd, a) {} longlong val_int(); const char *func_name() const { return "inet_aton"; } - void fix_length_and_dec() + bool fix_length_and_dec() { decimals= 0; max_length= 21; maybe_null= 1; unsigned_flag= 1; + return FALSE; } Item *get_copy(THD *thd, MEM_ROOT *mem_root) { return get_item_copy<Item_func_inet_aton>(thd, mem_root, this); } @@ -53,11 +54,12 @@ public: { } String* val_str(String* str); const char *func_name() const { return "inet_ntoa"; } - void fix_length_and_dec() + bool fix_length_and_dec() { decimals= 0; fix_length_and_charset(3 * 8 + 7, default_charset()); maybe_null= 1; + return FALSE; } Item *get_copy(THD *thd, MEM_ROOT *mem_root) { return get_item_copy<Item_func_inet_ntoa>(thd, mem_root, this); } @@ -122,11 +124,12 @@ public: virtual const char *func_name() const { return "inet6_aton"; } - virtual void fix_length_and_dec() + virtual bool fix_length_and_dec() { decimals= 0; fix_length_and_charset(16, &my_charset_bin); maybe_null= 1; + return FALSE; } Item *get_copy(THD *thd, MEM_ROOT *mem_root) { return get_item_copy<Item_func_inet6_aton>(thd, mem_root, this); } @@ -151,7 +154,7 @@ public: virtual const char *func_name() const { return "inet6_ntoa"; } - virtual void fix_length_and_dec() + virtual bool fix_length_and_dec() { decimals= 0; @@ -161,6 +164,7 @@ public: fix_length_and_charset(8 * 4 + 7, default_charset()); maybe_null= 1; + return FALSE; } Item *get_copy(THD *thd, MEM_ROOT *mem_root) { return get_item_copy<Item_func_inet6_ntoa>(thd, mem_root, this); } |