Suppress EPIPE and ECONNRESET tracebacks properly

Fixes #136.