avoid SIGPIPE errors throughout