diff options
Diffstat (limited to '')
-rw-r--r-- | src/cg-limits.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/cg-limits.c b/src/cg-limits.c index 78f0b6c..3f057bd 100644 --- a/src/cg-limits.c +++ b/src/cg-limits.c @@ -276,7 +276,7 @@ static int parse_double(double* restrict out, const char* restrict str) *out = strtod(str, &end); if (errno || isinf(*out) || isnan(*out) || *end) return -1; - if (!strchr("-0123456789.", *str)) + if (!*str || !strchr("-0123456789.", *str)) return -1; return 0; } |