CURLOPT_BUFFERSIZE must not be smaller than 0 (zero) as that is impossible
for us to deal with
This commit is contained in:
parent
a95df8246b
commit
fa162e8feb
@ -1177,7 +1177,8 @@ CURLcode Curl_setopt(struct SessionHandle *data, CURLoption option, ...)
|
||||
*/
|
||||
data->set.buffer_size = va_arg(param, long);
|
||||
|
||||
if(data->set.buffer_size> (BUFSIZE -1 ))
|
||||
if((data->set.buffer_size> (BUFSIZE -1 )) ||
|
||||
(data->set.buffer_size < 1))
|
||||
data->set.buffer_size = 0; /* huge internal default */
|
||||
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user