From 407b8acb5a324c01fc5c2bd62573393d117fa78e Mon Sep 17 00:00:00 2001 From: "C. McEnroe" Date: Sun, 22 Dec 2019 16:52:58 -0500 Subject: Revert "Exit when server gets POLLHUP" Turns out the more likely thing is that the fd will just continue to be POLLIN and produce zero-length reads. This reverts commit 5707b15920a1ce57f01db0d592487d833218be9d. --- bounce.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/bounce.c b/bounce.c index 8dc2850..2b1413d 100644 --- a/bounce.c +++ b/bounce.c @@ -413,10 +413,7 @@ int main(int argc, char *argv[]) { if (!revents) continue; if (event.fds[i].fd == server) { - if (revents & POLLIN) serverRecv(); - if (revents & (POLLHUP | POLLERR)) { - errx(EX_UNAVAILABLE, "server closed connection"); - } + serverRecv(); continue; } -- cgit 1.4.1