diff --git a/Zend/tests/bug42143.phpt b/Zend/tests/bug42143.phpt new file mode 100644 index 00000000000..8a73d41bf8e --- /dev/null +++ b/Zend/tests/bug42143.phpt @@ -0,0 +1,38 @@ +--TEST-- +bug #42143 (The constant NAN is reported as 0 on Windows build) +--CREDITS-- +Venkat Raman Don +--FILE-- + +--EXPECT-- +Testing NAN: +NAN= float(NAN) +bool(false) +bool(false) +bool(false) +bool(false) +bool(false) +float(NAN) +bool(false) +bool(false) +bool(false) +bool(true) +bool(true) +bool(false) + diff --git a/win32/build/config.w32.h.in b/win32/build/config.w32.h.in index ce1429c581f..ddb584927b7 100644 --- a/win32/build/config.w32.h.in +++ b/win32/build/config.w32.h.in @@ -160,7 +160,7 @@ #undef HAVE_ATOF_ACCEPTS_NAN #undef HAVE_ATOF_ACCEPTS_INF -#define HAVE_HUGE_VAL_NAN 1 +#define HAVE_HUGE_VAL_NAN 0 /* vs.net 2005 has a 64-bit time_t. This will likely break * 3rdParty libs that were built with older compilers; switch