From: Rene Scharfe Date: Thu, 28 Apr 2005 20:13:25 GMT Subject: Re: How to get bash to shut up about SIGPIPE? Message-ID: <427143E5.4080505@lsrfire.ath.cx> In-Reply-To: Linus Torvalds schrieb: > > On Thu, 28 Apr 2005, Rene Scharfe wrote: > >>I think you misspelled "cg-log". :-D > > > My fingers have a hard time learning new patterns, so I've got: > > torvalds@ppc970:~/git> cat ~/bin/git > #!/bin/sh > cmd="cg-$1" > shift > $cmd "$@" As a workaround, add this line after the shift to suppress the ugly messages: [ "$cmd" = cg-log ] && exec 2>/dev/null > Defining "DONT_REPORT_SIGPIPE" in config-top.h when building bash gets rid > of it, but I really don't want to rebuild bash just because of this ;) Yes, I just compiled it and in the version from gnu.org this defaults to not being defined. Man, am I glad my distro uncommented that line. :-) Looking briefly at the source there doesn't seem to be a way to turn it off besides this compile time setting. I really wonder why.. Rene