diff --git a/tests/numberparsingcheck.cpp b/tests/numberparsingcheck.cpp index cf7d49d3..aa95331f 100644 --- a/tests/numberparsingcheck.cpp +++ b/tests/numberparsingcheck.cpp @@ -54,7 +54,7 @@ inline void foundFloat(double result, const u8 * buf) { parse_error |= PARSE_ERROR; } // we want to get some reasonable relative accuracy - if(fabs(expected - result)/fmax(fabs(expected),fabs(result)) > 0.000000000000001) { + if(fabs(expected - result)/fmin(fabs(expected),fabs(result)) > 0.000000000000001) { printf("parsed %.32f from \n", result); printf(" %.32s whereas strtod gives\n", buf); printf(" %.32f,", expected);