com php-src: Remove unnecessary strlen check: Zend/zend_strto d.c

From: Date: Sun, 08 May 2016 05:04:31 +0000
Subject: com php-src: Remove unnecessary strlen check: Zend/zend_strto d.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-92064@lists.php.net to get a copy of this message
Commit: b62f7e338d4c771243df9c145761cab34a127880 Author: Xinchen Hui <laruence@gmail.com> Sat, 7 May 2016 22:04:31 -0700 Parents: d33e71b3589b0ce7218dd1dd770edd0a4bd3264f Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=b62f7e338d4c771243df9c145761cab34a127880 Log: Remove unnecessary strlen check Changed paths: M Zend/zend_strtod.c Diff: diff --git a/Zend/zend_strtod.c b/Zend/zend_strtod.c index 889a316..a524e64 100644 --- a/Zend/zend_strtod.c +++ b/Zend/zend_strtod.c @@ -4416,13 +4416,6 @@ ZEND_API double zend_hex_strtod(const char *str, const char **endptr) int any = 0; double value = 0; - if (s[0] == '\0' || s[1] == '\0') { - if (endptr != NULL) { - *endptr = str; - } - return 0.0; - } - if (*s == '0' && (s[1] == 'x' || s[1] == 'X')) { s += 2; } @@ -4491,13 +4484,6 @@ ZEND_API double zend_bin_strtod(const char *str, const char **endptr) double value = 0; int any = 0; - if (str[0] == '\0' || str[1] == '\0') { - if (endptr != NULL) { - *endptr = str; - } - return 0.0; - } - if ('0' == *s && ('b' == s[1] || 'B' == s[1])) { s += 2; }

« previous php.cvs (#92064) next »