From 8661a0aacc01492e0436275ff36a21734f2541bb Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Sun, 6 Aug 2017 21:32:43 +0200 Subject: [PATCH] fixup: str2double bug --- src/tool_paramhlp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tool_paramhlp.c b/src/tool_paramhlp.c index 3c14d9d7d8..b9dedc989e 100644 --- a/src/tool_paramhlp.c +++ b/src/tool_paramhlp.c @@ -218,7 +218,7 @@ static ParameterError str2double(double *val, const char *str, long max) num = strtod(str, &endptr); if(errno == ERANGE) return PARAM_NUMBER_TOO_LARGE; - if((long)val > max) { + if((long)num > max) { /* too large */ return PARAM_NUMBER_TOO_LARGE; }