another glibc EIO workaround

Partial fix for #3737 and #3644
This commit is contained in:
Kurtis Rader 2017-01-15 19:27:53 -08:00
parent 7a80610300
commit d905ed33fe

View file

@ -929,6 +929,8 @@ void exec_job(parser_t &parser, job_t *j) {
bool builtin_io_done = do_builtin_io(outbuff.data(), outbuff.size(),
errbuff.data(), errbuff.size());
if (!builtin_io_done && errno != EPIPE) {
redirect_tty_output(); // workaround glibc bug
debug(0, "!builtin_io_done and errno != EPIPE");
show_stackframe(L'E');
}
fork_was_skipped = true;