summaryrefslogtreecommitdiff
path: root/sql/item.h
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2004-05-07 01:43:17 +0300
committerunknown <monty@mysql.com>2004-05-07 01:43:17 +0300
commitf3544f3c5dd137e125a980c151e53ab71b23aba5 (patch)
treef2717f686b72c32ff82659eaf22da3a53b8deb1a /sql/item.h
parentffdf46a58ac73ce0862f1cf632e4254170ed6116 (diff)
downloadmariadb-git-f3544f3c5dd137e125a980c151e53ab71b23aba5.tar.gz
Portability fixes
Change strtoll -> my_strtoll10() Fixed bug in my_strntoul() and my_strntol() where we got different values on 32 and 64 bit systems (Bug #3472) configure.in: Fixed problem on IRIX64 (One can't have AC_MSG_RESULT on same row as AC_DEFINE extra/my_print_defaults.c: Fixed wrong definition for 'verbose' include/my_global.h: Portability fix (IRIX64) libmysql/client_settings.h: Remove compiler warnings libmysql/libmysql.c: Remove compiler warnings mysql-test/r/func_str.result: Updated results mysql-test/r/key_cache.result: Updated results to not depend on key_blocks_unused mysql-test/t/func_str.test: More test of long overflow mysql-test/t/key_cache.test: Updated results to not depend on key_blocks_unused sql/item.cc: Portability fix (don't use strtoll()) sql/item.h: Portability fix (don't use strtoll()) sql/item_sum.h: Portability fix (don't use strtoll()) sql/item_timefunc.cc: Fixed compiler warning strings/ctype-simple.c: Fixed bug in my_strntoul() and my_strntol() where we got different values on 32 and 64 bit systems strings/ctype-ucs2.c: Fixed bug in my_strntoul() and my_strntol() where we got different values on 32 and 64 bit systems
Diffstat (limited to 'sql/item.h')
-rw-r--r--sql/item.h9
1 files changed, 2 insertions, 7 deletions
diff --git a/sql/item.h b/sql/item.h
index 780e2fcadac..99a0516e439 100644
--- a/sql/item.h
+++ b/sql/item.h
@@ -456,10 +456,7 @@ public:
#endif
Item_int(const char *str_arg,longlong i,uint length) :value(i)
{ max_length=length; name=(char*) str_arg; fixed= 1; }
- Item_int(const char *str_arg) :
- value(str_arg[0] == '-' ? strtoll(str_arg,(char**) 0,10) :
- (longlong) strtoull(str_arg,(char**) 0,10))
- { max_length= (uint) strlen(str_arg); name=(char*) str_arg; fixed= 1; }
+ Item_int(const char *str_arg, uint length=64);
enum Type type() const { return INT_ITEM; }
enum Item_result result_type () const { return INT_RESULT; }
enum_field_types field_type() const { return MYSQL_TYPE_LONGLONG; }
@@ -479,9 +476,7 @@ public:
class Item_uint :public Item_int
{
public:
- Item_uint(const char *str_arg, uint length) :
- Item_int(str_arg, (longlong) strtoull(str_arg, (char**) 0,10), length)
- { unsigned_flag= 1; }
+ Item_uint(const char *str_arg, uint length);
Item_uint(uint32 i) :Item_int((longlong) i, 10)
{ unsigned_flag= 1; }
double val()