| commit | b51e0742b9349c6414956570c76a2152f5b22106 | [log] [tgz] |
|---|---|---|
| author | Jay Satiro <raysatiro@yahoo.com> | Thu Nov 02 00:30:28 2017 -0400 |
| committer | Jay Satiro <raysatiro@yahoo.com> | Thu Nov 02 00:30:28 2017 -0400 |
| tree | e81d21b23a4f4157133fd3880731abb9b1438b4b | |
| parent | 544bfdebea2a9e8be1c01fc7954cd49638fe2803 [diff] |
url: fix CURLOPT_DNS_CACHE_TIMEOUT arg value check to allow -1 Prior to this change since f121575 (7.56.1+) CURLOPT_DNS_CACHE_TIMEOUT erroneously rejected -1 with CURLE_BAD_FUNCTION_ARGUMENT.
diff --git a/lib/url.c b/lib/url.c index c334578..2e801e5 100644 --- a/lib/url.c +++ b/lib/url.c
@@ -722,7 +722,7 @@ switch(option) { case CURLOPT_DNS_CACHE_TIMEOUT: arg = va_arg(param, long); - if(arg < 0) + if(arg < -1) return CURLE_BAD_FUNCTION_ARGUMENT; data->set.dns_cache_timeout = arg; break;