summaryrefslogtreecommitdiff
path: root/sql/item.cc
diff options
context:
space:
mode:
authorgkodinov@dl145s.mysql.com <>2006-11-29 11:48:44 +0100
committergkodinov@dl145s.mysql.com <>2006-11-29 11:48:44 +0100
commitb58b5518101ee5e4d8b6fabc67c07dd6cd5f08f7 (patch)
tree705a3f2438bde34c000204acb02832c960c8b9bc /sql/item.cc
parent1fbc0cfb2becb724c7bd560d598b2e25dfeba17c (diff)
parenteb1b05c0bd82309358575a5c0501494f7edcd65d (diff)
downloadmariadb-git-b58b5518101ee5e4d8b6fabc67c07dd6cd5f08f7.tar.gz
Merge dl145s.mysql.com:/data0/bk/team_tree_merge/mysql-5.0-opt
into dl145s.mysql.com:/data0/bk/team_tree_merge/MERGE2/mysql-5.1-opt
Diffstat (limited to 'sql/item.cc')
-rw-r--r--sql/item.cc24
1 files changed, 17 insertions, 7 deletions
diff --git a/sql/item.cc b/sql/item.cc
index e15672e4d45..e96111708eb 100644
--- a/sql/item.cc
+++ b/sql/item.cc
@@ -2208,12 +2208,6 @@ void Item_string::print(String *str)
}
-inline bool check_if_only_end_space(CHARSET_INFO *cs, char *str, char *end)
-{
- return str+ cs->cset->scan(cs, str, end, MY_SEQ_SPACES) == end;
-}
-
-
double Item_string::val_real()
{
DBUG_ASSERT(fixed == 1);
@@ -4850,6 +4844,22 @@ bool Item_field::send(Protocol *protocol, String *buffer)
}
+void Item_field::update_null_value()
+{
+ /*
+ need to set no_errors to prevent warnings about type conversion
+ popping up.
+ */
+ THD *thd= field->table->in_use;
+ int no_errors;
+
+ no_errors= thd->no_errors;
+ thd->no_errors= 1;
+ Item::update_null_value();
+ thd->no_errors= no_errors;
+}
+
+
Item_ref::Item_ref(Name_resolution_context *context_arg,
Item **item, const char *table_name_arg,
const char *field_name_arg)
@@ -6208,7 +6218,7 @@ bool Item_cache_row::null_inside()
}
else
{
- values[i]->val_int();
+ values[i]->update_null_value();
if (values[i]->null_value)
return 1;
}