summaryrefslogtreecommitdiff
path: root/libmysql
diff options
context:
space:
mode:
authorIgnacio Galarza <iggy@mysql.com>2009-03-17 16:29:24 -0400
committerIgnacio Galarza <iggy@mysql.com>2009-03-17 16:29:24 -0400
commit0d588edf61c93ab67fb7e26101a0fc00d021bb11 (patch)
tree3c313f70fd16653491985d8e8108fb5b99f0d5d0 /libmysql
parent5b7347bda31b9d66cd78937e5dc339f553b9a736 (diff)
parent7ca1ebd83a1a7d291593be7a94f5a37298dfc863 (diff)
downloadmariadb-git-0d588edf61c93ab67fb7e26101a0fc00d021bb11.tar.gz
auto-merge
Diffstat (limited to 'libmysql')
-rw-r--r--libmysql/libmysql.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libmysql/libmysql.c b/libmysql/libmysql.c
index 1dd32df7aff..50995601d1f 100644
--- a/libmysql/libmysql.c
+++ b/libmysql/libmysql.c
@@ -3833,13 +3833,13 @@ static void fetch_float_with_conversion(MYSQL_BIND *param, MYSQL_FIELD *field,
#undef NOT_FIXED_DEC
{
/*
- The 14 below is to ensure that the server and client has the same
+ DBL_DIG below is to ensure that the server and client has the same
precisions. This will ensure that on the same machine you get the
same value as a string independent of the protocol you use.
*/
sprintf(buff, "%-*.*g", (int) min(sizeof(buff)-1,
param->buffer_length),
- min(14,width), value);
+ min(DBL_DIG, width), value);
end= strcend(buff, ' ');
*end= 0;
}