gunzip | tar reports broken pipe during OOO build on amd64.

Tim Kientzle kientzle at
Thu May 7 23:09:38 UTC 2009

Alexey Shuvaev wrote:
> Hello all!
> I was trying to upgrade editors/ recently and
> build failed for me at:
> The reason appeared to be the first part of the command
> "gunzip -c ... | ( tar -xf - ) &&  touch ..."
> which exited with non-zero exit status (141) and "touch ..." was not called.
> Running the command manually has showed that gunzip was complaining about
> broken pipe (however the archive was extracted successfully).

I just committed r191904, which should fix the tar problem
(actually, a libarchive problem) that caused this.

This problem was introduced in r191171 on 2009-04-16
when I went a little too far trying to eliminate some
duplicated code.  As a result, tar was no longer flushing
the pipe after it hit end-of-archive, which caused
gunzip to receive SIGPIPE for the final writes.
This only causes problems with /bin/csh, which reports
the exit status of the first command in a pipeline
(unlike /bin/sh, which reports the exit status of
the last command).


More information about the freebsd-current mailing list