Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 13 Nov 1999 02:13:41 +1100 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        cracauer@freebsd.org
Cc:        current@freebsd.org
Subject:   shell pipeline bug
Message-ID:  <Pine.BSF.4.10.9911130146270.17701-100000@alphplex.bde.org>

next in thread | raw e-mail | index | archive | help
`man sh' now hangs when the pager is exited.  This is caused by the recent
change to sh/eval.c

Simplified example:

    sh -c "jot 6000 | cat | head"

hangs.  This example is almost minimal.  The size of the data written
by the first command must be large enough to not fit in the pipe; the
middle command must be there, and the last command in the pipe must
exit before reading all the data.

The middle command should be killed by SIGPIPE when its output pipe is
closed; this output pipe should be closed when the final command exits,
but this is not happening because the shell is holding it open.

Bruce



To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.4.10.9911130146270.17701-100000>