diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/libtls/tls_socket.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libtls/tls_socket.c b/src/libtls/tls_socket.c index 9427b677c..2ccd97571 100644 --- a/src/libtls/tls_socket.c +++ b/src/libtls/tls_socket.c @@ -308,7 +308,7 @@ METHOD(tls_socket_t, splice, bool, DBG1(DBG_TLS, "TLS select error: %s", strerror(errno)); return FALSE; } - while (!plain_eof && pfd[0].revents & POLLIN) + while (!plain_eof && pfd[0].revents & (POLLIN | POLLHUP | POLLNVAL)) { in = read_(this, buf, sizeof(buf), FALSE); switch (in) @@ -341,7 +341,7 @@ METHOD(tls_socket_t, splice, bool, } break; } - if (!crypto_eof && pfd[1].revents & POLLIN) + if (!crypto_eof && pfd[1].revents & (POLLIN | POLLHUP | POLLNVAL)) { in = read(rfd, buf, sizeof(buf)); switch (in) |