Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uwm.edu!linac!pacific.mps.ohio-state.edu!zaphod.mps.ohio-state.edu!rpi!ispd-newsserver!garden.ssd.kodak.com!weimer From: weimer@garden.ssd.kodak.com (Gary Weimer (253-7796)) Newsgroups: comp.unix.shell Subject: Re: Bash, tar, and broken pipe Message-ID: <1991May15.155040.19078@ssd.kodak.com> Date: 15 May 91 15:50:40 GMT References: <586@kepler1.kepler.com> Sender: news@ssd.kodak.com Reply-To: weimer@ssd.kodak.com Organization: Eastman Kodak Co.; Rochester, NY Lines: 27 In article <586@kepler1.kepler.com>, jwu@kepler.com (Jasper Wu) writes: |> |> I have some problem when using pipelined tar in bash and hope someone |> can help me find out why. |> |> When I do |> zcat foo.tar.Z | tar tvfB - |> or uncompress < foo.tar.Z | tar tvfB - |> |> it gives me the table of contents correctly but reports an error |> message "Broken pipe" to stderr when it finishes. However, if i add |> a "cat" to the pipeline as |> cat foo.tar.Z | uncompress | tar tvfB - |> |> then it works fine (i.e., no error message). All commands above work fine |> in csh or sh. In csh I use: uncompress -c foo.tar.Z | tar tvf - ^^ (I've never had a problem not using B for tar). I don't know if this will fix your problem or not. weimer@ssd.kodak.com ( Gary Weimer )