diff options
author | Xinchen Hui <laruence@gmail.com> | 2016-05-07 22:04:31 -0700 |
---|---|---|
committer | Xinchen Hui <laruence@gmail.com> | 2016-05-07 22:04:31 -0700 |
commit | b62f7e338d4c771243df9c145761cab34a127880 (patch) | |
tree | 84761fc8ee52572f4a35d6f511f74898904a7f9c | |
parent | d33e71b3589b0ce7218dd1dd770edd0a4bd3264f (diff) | |
download | php-git-b62f7e338d4c771243df9c145761cab34a127880.tar.gz |
Remove unnecessary strlen check
-rw-r--r-- | Zend/zend_strtod.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/Zend/zend_strtod.c b/Zend/zend_strtod.c index 889a31685c..a524e64aa1 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; } |