From 49e45baf9bd3bd084bc29be24e94a56f6c0d702c Mon Sep 17 00:00:00 2001 From: Zeev Suraski Date: Mon, 13 Aug 2001 00:32:04 +0000 Subject: [PATCH] - Fix API - Update NEWS --- NEWS | 2 ++ ext/standard/basic_functions.c | 2 +- ext/standard/datetime.c | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/NEWS b/NEWS index 122e251c91..29110bf712 100644 --- a/NEWS +++ b/NEWS @@ -1,6 +1,8 @@ PHP 4.0 NEWS ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||| ?? ??? 200?, Version 4.0.7-dev +- Floating point numbers are better detected when converting from strings + (Zeev, Zend Engine) - Replaced php.ini-optimized with php.ini-recommended. As the name implies, it's warmly recommended to use this file as the basis for your PHP configuration, rather than php.ini-dist. (Zeev) diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c index 18befd4c4a..5501934dee 100644 --- a/ext/standard/basic_functions.c +++ b/ext/standard/basic_functions.c @@ -1470,7 +1470,7 @@ PHP_FUNCTION(is_numeric) break; case IS_STRING: - result = is_numeric_string(Z_STRVAL_PP(arg), Z_STRLEN_PP(arg), NULL, NULL); + result = is_numeric_string(Z_STRVAL_PP(arg), Z_STRLEN_PP(arg), NULL, NULL, 0); if (result == IS_LONG || result == IS_DOUBLE) { RETURN_TRUE; } else { diff --git a/ext/standard/datetime.c b/ext/standard/datetime.c index 7ee353110e..8f9ed8f593 100644 --- a/ext/standard/datetime.c +++ b/ext/standard/datetime.c @@ -690,7 +690,7 @@ PHP_FUNCTION(checkdate) } if((*year)->type == IS_STRING) { - res = is_numeric_string((*year)->value.str.val, (*year)->value.str.len, NULL, NULL); + res = is_numeric_string((*year)->value.str.val, (*year)->value.str.len, NULL, NULL, 0); if(res!=IS_LONG && res !=IS_DOUBLE) { RETURN_FALSE; } -- 2.50.1