input/curl: implement a hard-coded timeout of 10 seconds
Be sure to stop the operation at some point when the server isn't responding.
This commit is contained in:
parent
b3df4dc2c9
commit
11626e48bf
1
NEWS
1
NEWS
|
@ -4,6 +4,7 @@ ver 0.16.4 (2011/??/??)
|
||||||
* apply follow_inside_symlinks to absolute symlinks
|
* apply follow_inside_symlinks to absolute symlinks
|
||||||
* input:
|
* input:
|
||||||
- curl: limit the receive buffer size
|
- curl: limit the receive buffer size
|
||||||
|
- curl: implement a hard-coded timeout of 10 seconds
|
||||||
* decoder:
|
* decoder:
|
||||||
- ffmpeg: workaround for semantic API change in recent ffmpeg versions
|
- ffmpeg: workaround for semantic API change in recent ffmpeg versions
|
||||||
- flac: validate the sample rate when scanning the tag
|
- flac: validate the sample rate when scanning the tag
|
||||||
|
|
|
@ -680,6 +680,9 @@ input_curl_easy_init(struct input_curl *c, GError **error_r)
|
||||||
curl_easy_setopt(c->easy, CURLOPT_MAXREDIRS, 5);
|
curl_easy_setopt(c->easy, CURLOPT_MAXREDIRS, 5);
|
||||||
curl_easy_setopt(c->easy, CURLOPT_FAILONERROR, true);
|
curl_easy_setopt(c->easy, CURLOPT_FAILONERROR, true);
|
||||||
curl_easy_setopt(c->easy, CURLOPT_ERRORBUFFER, c->error);
|
curl_easy_setopt(c->easy, CURLOPT_ERRORBUFFER, c->error);
|
||||||
|
curl_easy_setopt(c->easy, CURLOPT_NOPROGRESS, 1l);
|
||||||
|
curl_easy_setopt(c->easy, CURLOPT_NOSIGNAL, 1l);
|
||||||
|
curl_easy_setopt(c->easy, CURLOPT_CONNECTTIMEOUT, 10l);
|
||||||
|
|
||||||
if (proxy != NULL)
|
if (proxy != NULL)
|
||||||
curl_easy_setopt(c->easy, CURLOPT_PROXY, proxy);
|
curl_easy_setopt(c->easy, CURLOPT_PROXY, proxy);
|
||||||
|
|
Loading…
Reference in New Issue