-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
According to Ralf Wildenhues on 11/11/2008 12:35 PM:
> I haven't found a shell that needs this subshell, but this:
> $ echo '...' | ./foo 2>/dev/null
>
> causes this output from some bash versions:
> | bash: echo: write error: Broken pipe
But doesn't that only happen if ./foo exits prior to echo being able to
push all its output? I guess if the shell can't handle the input, it will
exit early, but maybe we could write this as:
echo '...' | { ./foo 2>/dev/null; as_status=$?; cat >/dev/null;
test $as_status = 0; }
so that there is something to consume all of the echo output? But I don't
think we have to worry about this unless we get actual reports of a noisy
echo.
- --
Don't work too hard, make some time for fun as well!
Eric Blake [EMAIL PROTECTED]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iEYEARECAAYFAkkaRLcACgkQ84KuGfSFAYCw6gCfZwIupGPQhGYzXdjxBdyls3MY
F2IAmwT/SA7w0sERYVBCgG3HdTDHpj20
=JwnQ
-----END PGP SIGNATURE-----