From: Johannes Sixt <j6t@kdbg.org>
To: Junio C Hamano <gitster@pobox.com>
Cc: Jehan Bing <jehan@orb.com>,
git@vger.kernel.org, peff@peff.net, jrnieder@gmail.com
Subject: Re: [PATCH] Ignore SIGPIPE when running a filter driver
Date: Tue, 21 Feb 2012 20:20:38 +0100 [thread overview]
Message-ID: <4F43EE86.3000307@kdbg.org> (raw)
In-Reply-To: <7vsji5jgtv.fsf@alter.siamese.dyndns.org>
Am 20.02.2012 23:11, schrieb Junio C Hamano:
> Jehan Bing <jehan@orb.com> writes:
>> @@ -360,12 +361,16 @@ static int filter_buffer(int in, int out, void *data)
>> if (start_command(&child_process))
>> return error("cannot fork to run external filter %s", params->cmd);
>>
>> + sigchain_push(SIGPIPE, SIG_IGN);
>> +
>> write_err = (write_in_full(child_process.in, params->src, params->size) < 0);
>> if (close(child_process.in))
>> write_err = 1;
>> if (write_err)
>> error("cannot feed the input to external filter %s", params->cmd);
>>
>> + sigchain_pop(SIGPIPE);
>> +
>
> Thanks.
>
> I think this is OK on a POSIX system where this function is run by
> start_async() which is implemented with a forked child process.
>
> I do not now if it poses a issue on Windows, though. Johannes, any
> comments?
I do not expect the change to cause a problem on Windows.
-- Hannes
next prev parent reply other threads:[~2012-02-21 19:20 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-20 20:53 [PATCH] Ignore SIGPIPE when running a filter driver Jehan Bing
2012-02-20 22:11 ` Junio C Hamano
2012-02-21 19:20 ` Johannes Sixt [this message]
2012-02-21 3:01 ` Jonathan Nieder
2012-02-21 20:58 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4F43EE86.3000307@kdbg.org \
--to=j6t@kdbg.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jehan@orb.com \
--cc=jrnieder@gmail.com \
--cc=peff@peff.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).