From 87c1327cf66b740a1ef537862a326d265898cb5e Mon Sep 17 00:00:00 2001 From: Costa Tsaousis Date: Sun, 29 May 2016 23:52:45 +0300 Subject: [PATCH] changed PLUS with OR for poll events --- src/web_client.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/web_client.c b/src/web_client.c index c594ae23..b4e07ff4 100644 --- a/src/web_client.c +++ b/src/web_client.c @@ -2134,8 +2134,8 @@ void *web_client_main(void *ptr) fds[0].events = 0; fds[0].revents = 0; - if(w->wait_receive) fds[0].events += POLLIN; - if(w->wait_send) fds[0].events += POLLOUT; + if(w->wait_receive) fds[0].events |= POLLIN; + if(w->wait_send) fds[0].events |= POLLOUT; fds[1].fd = -1; fds[1].events = 0; @@ -2149,13 +2149,13 @@ void *web_client_main(void *ptr) fds[0].fd = w->ifd; fds[0].events = 0; fds[0].revents = 0; - if(w->wait_receive) fds[0].events += POLLIN; + if(w->wait_receive) fds[0].events |= POLLIN; ifd = &fds[0]; fds[1].fd = w->ofd; fds[1].events = 0; fds[1].revents = 0; - if(w->wait_send) fds[1].events += POLLOUT; + if(w->wait_send) fds[1].events |= POLLOUT; ofd = &fds[1]; fdmax = 2; -- 2.39.2