summaryrefslogtreecommitdiff
path: root/sql/item_func.h
diff options
context:
space:
mode:
authorunknown <Sinisa@sinisa.nasamreza.org>2004-01-09 22:28:29 +0200
committerunknown <Sinisa@sinisa.nasamreza.org>2004-01-09 22:28:29 +0200
commitd84ee4d503783a174346393436e7a8ecc7b941bd (patch)
tree98f4fd0bc97145251b223e218e21c8f1f8a2228b /sql/item_func.h
parent229cc612776f757de6822eb97eb4e9a97226e760 (diff)
downloadmariadb-git-d84ee4d503783a174346393436e7a8ecc7b941bd.tar.gz
null.result, null.test:
Fix for a bug #2219, regarding a bad cast to integer from NULL item_func.h: Fix for a bug #2219, regarding a bad cast to integer from NULL sql_parse.cc: A fix for a bug #2207, with mysql server haning on option setting sql/sql_parse.cc: A fix for a bug #2207, with mysql server haning on option setting sql/item_func.h: Fix for a bug #2219, regarding a bad cast to integer from NULL mysql-test/t/null.test: Fix for a bug #2219, regarding a bad cast to integer from NULL mysql-test/r/null.result: Fix for a bug #2219, regarding a bad cast to integer from NULL
Diffstat (limited to 'sql/item_func.h')
-rw-r--r--sql/item_func.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/sql/item_func.h b/sql/item_func.h
index ac67b5a4065..33a4357d26c 100644
--- a/sql/item_func.h
+++ b/sql/item_func.h
@@ -212,8 +212,8 @@ class Item_func_signed :public Item_int_func
{
public:
Item_func_signed(Item *a) :Item_int_func(a) {}
- double val() { return args[0]->val(); }
- longlong val_int() { return args[0]->val_int(); }
+ double val() { null_value=args[0]->null_value; return args[0]->val(); }
+ longlong val_int() { null_value=args[0]->null_value; return args[0]->val_int(); }
void fix_length_and_dec()
{ max_length=args[0]->max_length; unsigned_flag=0; }
void print(String *str);
@@ -224,8 +224,8 @@ class Item_func_unsigned :public Item_int_func
{
public:
Item_func_unsigned(Item *a) :Item_int_func(a) {}
- double val() { return args[0]->val(); }
- longlong val_int() { return args[0]->val_int(); }
+ double val() { null_value=args[0]->null_value; return args[0]->val(); }
+ longlong val_int() { null_value=args[0]->null_value; return args[0]->val_int(); }
void fix_length_and_dec()
{ max_length=args[0]->max_length; unsigned_flag=1; }
void print(String *str);