Tell curl that we are a multi-threaded program - i. e. it can not use signals.

Signed-off-by: Stanislav Brabec <sbrabec@suse.cz>
This commit is contained in:
Stanislav Brabec 2011-07-13 21:16:04 -07:00 committed by David Benjamin
parent 304a86f7b8
commit 8f3be9a1f8
1 changed files with 2 additions and 0 deletions

View File

@ -1233,6 +1233,7 @@ np_stream_new (const gchar *url, void *notify_data)
return NULL;
curl_easy_setopt (handle, CURLOPT_URL, url);
curl_easy_setopt (handle, CURLOPT_NOSIGNAL, 1);
curl_easy_setopt (handle, CURLOPT_WRITEFUNCTION, on_stream_read_nothing_cb);
curl_easy_setopt (handle, CURLOPT_FILETIME, 1);
curl_easy_setopt (handle, CURLOPT_TIMECONDITION, CURL_TIMECOND_LASTMOD);
@ -1626,6 +1627,7 @@ on_stream_open_cb (gpointer user_data)
CURL * const handle = pstream->curl_handle;
curl_easy_setopt (handle, CURLOPT_URL, pstream->np_stream->url);
curl_easy_setopt (handle, CURLOPT_NOSIGNAL, 1);
curl_easy_setopt (handle, CURLOPT_WRITEFUNCTION, on_stream_read_cb);
curl_easy_setopt (handle, CURLOPT_WRITEDATA, pstream);
curl_easy_setopt (handle, CURLOPT_PRIVATE, pstream);