3 ms·
You might want to `set -o pipefail` on your bash because a failing process does not stop things from getting piped: `echo OK | false | echo OK2` --> this comm
by aablkn 12y ago
You might want to `set -o pipefail` on your bash because a failing process does not stop things from getting piped:
`echo OK | false | echo OK2` --> this command returns zero exit code even though false does return non-zero exit code. If you do `set -o pipefail` entire pipe will fail with non-zero exit code (of `false`).
- _prometheus 12y agogreat point. if you have a good idea of how hashpipe should do it better pls comment at: https://github.com/jbenet/hashpipe/issues https://github.com/jbenet/hashpipe/issues at least hashpipe stops the output, so this would not run the bad code. hashpipe would stop it: cat evil | hashpipe <some-other-hash> | sh without pipefail, it would still exit 0, but at least the evil would be contained.