From: sinisa Date: January 9 2004 8:28pm Subject: bk commit into 4.1 tree (Sinisa:1.1665) List-Archive: http://lists.mysql.com/internals/11607 Message-Id: <200401092028.i09KSYnv012435@sinisa.nasamreza.org> Below is the list of changes that have just been committed into a local 4.1 repository of Sinisa. When Sinisa does a push these changes will be propagated to the main repository and, within 24 hours after the push, to the public repository. For information on how to access the public repository see http://www.mysql.com/doc/I/n/Installing_source_tree.html ChangeSet 1.1665 04/01/09 22:28:29 Sinisa@stripped +4 -0 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 mysql-test/r/null.result 1.20 04/01/09 22:27:20 Sinisa@stripped +3 -0 Fix for a bug #2219, regarding a bad cast to integer from NULL mysql-test/t/null.test 1.12 04/01/09 22:27:02 Sinisa@stripped +1 -0 Fix for a bug #2219, regarding a bad cast to integer from NULL sql/item_func.h 1.98 04/01/09 22:26:12 Sinisa@stripped +4 -4 Fix for a bug #2219, regarding a bad cast to integer from NULL sql/sql_parse.cc 1.317 04/01/09 17:42:03 Sinisa@stripped +2 -0 A fix for a bug #2207, with mysql server haning on option setting # This is a BitKeeper patch. What follows are the unified diffs for the # set of deltas contained in the patch. The rest of the patch, the part # that BitKeeper cares about, is below these diffs. # User: Sinisa # Host: sinisa.nasamreza.org # Root: /mnt/work/mysql-4.1 --- 1.97/sql/item_func.h Fri Dec 19 16:25:45 2003 +++ 1.98/sql/item_func.h Fri Jan 9 22:26:12 2004 @@ -212,8 +212,8 @@ { 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 @@ { 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); --- 1.316/sql/sql_parse.cc Wed Dec 24 15:57:24 2003 +++ 1.317/sql/sql_parse.cc Fri Jan 9 17:42:03 2004 @@ -1624,9 +1624,11 @@ switch (command) { case MYSQL_OPTION_MULTI_STATEMENTS_ON: thd->client_capabilities|= CLIENT_MULTI_STATEMENTS; + send_eof(thd); break; case MYSQL_OPTION_MULTI_STATEMENTS_OFF: thd->client_capabilities&= ~CLIENT_MULTI_STATEMENTS; + send_eof(thd); break; default: send_error(thd, ER_UNKNOWN_COM_ERROR); --- 1.19/mysql-test/r/null.result Wed Dec 10 06:30:21 2003 +++ 1.20/mysql-test/r/null.result Fri Jan 9 22:27:20 2004 @@ -153,3 +153,6 @@ id select_type table type possible_keys key key_len ref rows Extra 1 SIMPLE t1 range idx idx 4 NULL 2 Using where drop table t1; +select cast(NULL as signed); +cast(NULL as signed) +NULL --- 1.11/mysql-test/t/null.test Wed Dec 10 06:30:36 2003 +++ 1.12/mysql-test/t/null.test Fri Jan 9 22:27:02 2004 @@ -97,3 +97,4 @@ explain select * from t1 where a between 2 and 3; explain select * from t1 where a between 2 and 3 or b is null; drop table t1; +select cast(NULL as signed);