diff options
author | kaa@polly.(none) <> | 2007-12-01 15:25:24 +0300 |
---|---|---|
committer | kaa@polly.(none) <> | 2007-12-01 15:25:24 +0300 |
commit | 55acce750486f557b84610ce63545511aca89bed (patch) | |
tree | ef0425d76948e8696f54c69d42e7d37d7a11c274 /sql/field.cc | |
parent | 33125cd40ed2b92ee923c63bd81e153e0f5bc92c (diff) | |
download | mariadb-git-55acce750486f557b84610ce63545511aca89bed.tar.gz |
Fixed the floating point number tests on Windows.
Diffstat (limited to 'sql/field.cc')
-rw-r--r-- | sql/field.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sql/field.cc b/sql/field.cc index 1878797297f..a9aca5dc6e0 100644 --- a/sql/field.cc +++ b/sql/field.cc @@ -5954,7 +5954,7 @@ int Field_str::store(double nr) if (exp >= (int) digits || exp < -4) digits= max(0, (int) (max_length - 5 - (exp >= 100 || exp <= -100))); - length= (uint) my_sprintf(buff, (buff, "%-.*g", digits, nr)); + length= (uint) my_sprintf(buff, (buff, "%-.*g", min(digits, DBL_DIG ), nr)); #ifdef __WIN__ /* |