curl-library
Re: SIGPIPE when using libcurl with OpenSSL on Fedora 28
Date: Wed, 19 Dec 2018 15:52:04 +0000
Hi Tim,
On 19/12/2018 15:29, Tim Rühsen wrote:
> Maybe this is relevant !?
>
> commit 1b8ed4ad2318765665fef636a3d66b89fa4d8da6
> Author: Daniel Stenberg <daniel_at_haxx.se>
> Date: Tue Aug 21 14:52:17 2018 +0200
>
> libcurl-thread.3: expand somewhat on the NO_SIGNAL motivation
>
> Multi-threaded applictions basically MUST set CURLOPT_NO_SIGNAL to 1L to
> avoid the risk of getting a SIGPIPE.
>
> Either way, a multi-threaded application that uses libcurl/openssl needs
> to have a signhandler for or ignore SIGPIPE on its own.
>
> Based on discussions in #2800
> Closes #2904
>
>
> Regards, Tim
>
I was not aware that this was a requirement on multi-threaded
applications. The CURLOPT_NOSIGNAL API documentation [1] does not
reference this requirement at all, which is why I've missed it.
My application is multi-threaded, but I have a dedicated thread just for
running curl in - there should never be another thread which calls
curl_multi_perform. Would I need to set CURLOPT_NOSIGNAL even in this case?
Best Regards,
Sam
[1]: https://curl.haxx.se/libcurl/c/CURLOPT_NOSIGNAL.html
-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
- application/pgp-signature attachment: OpenPGP digital signature