summaryrefslogtreecommitdiff
path: root/sql
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2004-04-12 01:43:07 +0300
committerunknown <monty@mysql.com>2004-04-12 01:43:07 +0300
commit97eddaaf6de63886bbdc2b7a63c62618f427321a (patch)
tree3f612a50043fe61483fd12385876c47bf3017e10 /sql
parent19e4b52a79b8e646a7693a3fd574c086ba4f48a4 (diff)
parent70454de25abef86ea01eeac0eb164e79d8b3d26e (diff)
downloadmariadb-git-97eddaaf6de63886bbdc2b7a63c62618f427321a.tar.gz
Merge bk-internal.mysql.com:/home/bk/mysql-4.1
into mysql.com:/home/my/mysql-4.1 sql/item.cc: Auto merged
Diffstat (limited to 'sql')
-rw-r--r--sql/field.h1
-rw-r--r--sql/item.cc4
-rw-r--r--sql/item.h1
3 files changed, 3 insertions, 3 deletions
diff --git a/sql/field.h b/sql/field.h
index 4efabcead18..002a7228164 100644
--- a/sql/field.h
+++ b/sql/field.h
@@ -92,6 +92,7 @@ public:
utype unireg_check_arg, const char *field_name_arg,
struct st_table *table_arg);
virtual ~Field() {}
+ /* Store functions returns 1 on overflow and -1 on fatal error */
virtual int store(const char *to,uint length,CHARSET_INFO *cs)=0;
virtual int store(double nr)=0;
virtual int store(longlong nr)=0;
diff --git a/sql/item.cc b/sql/item.cc
index adaae50f0d2..2584c1cafb3 100644
--- a/sql/item.cc
+++ b/sql/item.cc
@@ -678,9 +678,7 @@ void Item_param::set_longdata(const char *str, ulong length)
int Item_param::save_in_field(Field *field, bool no_conversions)
{
- THD *thd= current_thd;
-
- DBUG_ASSERT(thd->command == COM_EXECUTE);
+ DBUG_ASSERT(current_thd->command == COM_EXECUTE);
if (null_value)
return (int) set_field_to_null(field);
diff --git a/sql/item.h b/sql/item.h
index 902f42dd07c..0f2927b0d99 100644
--- a/sql/item.h
+++ b/sql/item.h
@@ -146,6 +146,7 @@ public:
complete fix_fields() procedure.
*/
inline void quick_fix_field() { fixed= 1; }
+ /* Function returns 1 on overflow and -1 on fatal errors */
virtual int save_in_field(Field *field, bool no_conversions);
virtual void save_org_in_field(Field *field)
{ (void) save_in_field(field, 1); }