mirror of
https://github.com/curl/curl.git
synced 2024-11-21 01:16:58 +08:00
curl: --local-port range was not "including"
The end port number in a given range was not included in the range used, as it is documented to be. Reported-by: infinnovation-dev on github Fixes #3251 Closes #3255
This commit is contained in:
parent
27cb384679
commit
fcf3f13368
@ -958,7 +958,7 @@ ParameterError getparameter(const char *flag, /* f or -long-flag */
|
||||
err = str2unum(&config->localportrange, lrange);
|
||||
if(err || (config->localportrange > 65535))
|
||||
return PARAM_BAD_USE;
|
||||
config->localportrange -= config->localport;
|
||||
config->localportrange -= (config->localport-1);
|
||||
if(config->localportrange < 1)
|
||||
return PARAM_BAD_USE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user