bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#14246: tee can't continue when receiving SIGPIPE + adding a text mod


From: Pádraig Brady
Subject: bug#14246: tee can't continue when receiving SIGPIPE + adding a text mode option
Date: Tue, 23 Apr 2013 16:58:55 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2

On 04/23/2013 01:57 PM, Camion SPAM wrote:
> Hello, I could like to suggest the following patch for tee.
> It addresses the following problems : 
> 1/ Add a new -t parametre to have tee work line per line instead of block by 
> block (Usefull if you use tee to check script results while they are sent to 
> a file or anywhere else

tee works in non buffered mode by default
so I need to consider the implications of  "text mode".

> 2/ Ignores SIGPIPE so that it can close a broken pipe and continue tee-ing on 
> others.

The more general tee --write-error={[cont],ignore,exit}
should handle this http://bugs.gnu.org/11540
It's nearly at the top of my TODO list.

> This is useful when you write things like this 
> 
> $(some_command | tee /dev/fd/3 | some_processing_1) 3>&1 | 
> processing_2_not_reading_up_to_the_end
> 
> In this case, when processing_2 stops reading, tee will receive SIGPIPE and 
> will be killed preventing processing_1 from receiving it's data.

thanks,
Pádraig.







reply via email to

[Prev in Thread] Current Thread [Next in Thread]