From 2cf209d3f777d6cfeba9b82a4d26ef47b89e8140 Mon Sep 17 00:00:00 2001 From: Daniel Stenberg Date: Tue, 2 Dec 2003 10:12:44 +0000 Subject: If HAVE_MSG_NOSIGNAL is set, we use MSG_NOSIGNAL when we call send() and recv() and we no longer attempt to ignore the SIGPIPE signal. --- lib/transfer.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/transfer.c') diff --git a/lib/transfer.c b/lib/transfer.c index 81a52a590..15c74c951 100644 --- a/lib/transfer.c +++ b/lib/transfer.c @@ -1457,7 +1457,7 @@ CURLcode Curl_pretransfer(struct SessionHandle *data) * different ports! */ data->state.allow_port = TRUE; -#if defined(HAVE_SIGNAL) && defined(SIGPIPE) +#if defined(HAVE_SIGNAL) && defined(SIGPIPE) && !defined(HAVE_MSG_NOSIGNAL) /************************************************************* * Tell signal handler to ignore SIGPIPE *************************************************************/ @@ -1473,7 +1473,7 @@ CURLcode Curl_pretransfer(struct SessionHandle *data) CURLcode Curl_posttransfer(struct SessionHandle *data) { -#if defined(HAVE_SIGNAL) && defined(SIGPIPE) +#if defined(HAVE_SIGNAL) && defined(SIGPIPE) && !defined(HAVE_MSG_NOSIGNAL) /* restore the signal handler for SIGPIPE before we get back */ if(!data->set.no_signal) signal(SIGPIPE, data->state.prev_signal); -- cgit v1.2.3