[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] Terminate zgrep gracefully when a pipeline is interrupted by
Re: [PATCH] Terminate zgrep gracefully when a pipeline is interrupted by a signal
Thu, 04 Feb 2010 07:18:48 +0100
Dmitry V. Levin wrote:
> On Wed, Feb 03, 2010 at 06:32:52AM +0100, Jim Meyering wrote:
>> Dmitry V. Levin wrote:
>> > OK, shall I repost the patch with these changes applied?
>> Not required, but would be nice.
>> If it's not too much trouble, would you please add a test, too?
> Subject: [PATCH] zgrep: terminate gracefully when a pipeline is interrupted
> by a signal
> zgrep is not terminated gracefully when its grep/sed pipeline
> is terminated by a signal. For example, a command like
> zgrep -F .TH /usr/share/man/man1/*.gz | head
> works long time after the "head" completion.
> Another example, a command like
> zgrep unmatched-pattern /usr/share/man/man1/*.gz
> cannot be interrupted by sending a SIGQUIT with Ctrl-\ key, it outputs
> zgrep: line 221: test: : integer expression expected
> and goes on.
> * zgrep.in: Terminate gracefully when the grep/sed pipeline is
> terminated by a signal.
> * tests/zgrep-signal: New test.
> * Makefile.am (TESTS): Add it.
Thanks. I've pushed that.
FYI, the only change was to replace the single leading TAB with spaces,
to appease "make syntax-check".