summaryrefslogtreecommitdiff
path: root/sql-common
diff options
context:
space:
mode:
authorGuilhem Bichot <guilhem@mysql.com>2009-09-30 12:25:50 +0200
committerGuilhem Bichot <guilhem@mysql.com>2009-09-30 12:25:50 +0200
commitb3886f46da6278b511de9f07cbfa884ef09e18bb (patch)
treeed4d4bd9316c084770e810815274ca29e6434ffb /sql-common
parent70cb38ec825243d6930bcadde0669cecd246d1f5 (diff)
downloadmariadb-git-b3886f46da6278b511de9f07cbfa884ef09e18bb.tar.gz
Fix for BUG#42980 "Client doesn't set NUM_FLAG for DECIMAL and TIMESTAMP":
DECIMAL and TIMESTAMP used to have NUM_FLAG, but NEWDECIMAL was forgotten. It's correct that TIMESTAMP does not have the flag nowadays (manual will be updated, connectors developers will be notified).
Diffstat (limited to 'sql-common')
-rw-r--r--sql-common/client.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sql-common/client.c b/sql-common/client.c
index 84029b449af..a502e0ea195 100644
--- a/sql-common/client.c
+++ b/sql-common/client.c
@@ -1313,7 +1313,7 @@ unpack_fields(MYSQL_DATA *data,MEM_ROOT *alloc,uint fields,
field->flags= uint2korr(pos+7);
field->decimals= (uint) pos[9];
- if (INTERNAL_NUM_FIELD(field))
+ if (IS_NUM(field->type))
field->flags|= NUM_FLAG;
if (default_value && row->data[7])
{
@@ -1354,7 +1354,7 @@ unpack_fields(MYSQL_DATA *data,MEM_ROOT *alloc,uint fields,
field->flags= (uint) (uchar) row->data[4][0];
field->decimals=(uint) (uchar) row->data[4][1];
}
- if (INTERNAL_NUM_FIELD(field))
+ if (IS_NUM(field->type))
field->flags|= NUM_FLAG;
if (default_value && row->data[5])
{