diff options
Diffstat (limited to 'stdlib/strtod.c')
-rw-r--r-- | stdlib/strtod.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/stdlib/strtod.c b/stdlib/strtod.c index 6bd2dd6..989984e 100644 --- a/stdlib/strtod.c +++ b/stdlib/strtod.c @@ -396,7 +396,7 @@ STRTOF (nptr, endptr) /* Return 0.0 if no legal string is found. No character is used even if a sign was found. */ - if (!isdigit (c)) + if (!isdigit (c) && (c != decimal || !isdigit (cp[1]))) RETURN (0.0, nptr); /* Record the start of the digits, in case we will check their grouping. */ |