diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2010-05-14 16:54:39 +0200 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2010-05-14 16:54:39 +0200 |
commit | 475977242ac5bb9ff8826c2dd8c9a1a180320de2 (patch) | |
tree | 492a30a92b83d398635c5c4e720ae140a1a53513 /sysdep/unix/io.c | |
parent | 0267f49fb2e44525aa2777bcb9900c4bb2db41e1 (diff) |
Handle EPIPE as a common connection close event.
Diffstat (limited to 'sysdep/unix/io.c')
-rw-r--r-- | sysdep/unix/io.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sysdep/unix/io.c b/sysdep/unix/io.c index dc7146f5..456644b2 100644 --- a/sysdep/unix/io.c +++ b/sysdep/unix/io.c @@ -1216,7 +1216,8 @@ sk_maybe_write(sock *s) if (errno != EINTR && errno != EAGAIN) { reset_tx_buffer(s); - s->err_hook(s, errno); + /* EPIPE is just a connection close notification during TX */ + s->err_hook(s, (errno != EPIPE) ? errno : 0); return -1; } return 0; |