Created attachment 5298 Patch to set SIGPIPE to SIG_DFL before spawning a shell A fuller log of the problems this causes can be found at http://bugs.debian.org/733722 A brief summary: running a shell in an xfce4-terminal sometimes causes weird SIGPIPE errors, such as the following: erdos:~ $ ls /media/JG-BACKUP/mythtv/recordings/ | head -n1 1001_20121224170300.mpg ls: write error: Broken pipe There is no reason for a broken pipe here! It turns out that the cause is that xfce4-terminal sets SIGPIPE to be ignored (to fix https://bugzilla.xfce.org/show_bug.cgi?id=2349) but doesn't reset it to its default status before launching a shell. The attached (and tested) patch does this, and it does not appear to reawaken the problem experienced in that bug. There is also another tiny bugfix in this patch: since the #include <signal.h> is enclosed within an #ifdef HAVE_SIGNAL_H clause, I've enclosed the call to signal() within a similar clause in main.c.
(Actually, this also applies to 0.6.3, but there isn't an option to select that version.)
Actually, on reflection, a better way of fixing this bug may be to restrict the SIGPIPE ignoring to only those situations where this is actually desired, so the cases listed in the now-fixed bug 2349. But I haven't looked into how to code that up.
vte3 fixed this at one point (and then further refactored in https://git.gnome.org/browse/vte/commit/?id=171b8aa).
So should this one be resolved?
I think so.
Ok then, closing.