diff options
author | Igor Sysoev <igor@sysoev.ru> | 2020-04-15 14:54:09 +0300 |
---|---|---|
committer | Igor Sysoev <igor@sysoev.ru> | 2020-04-15 14:54:09 +0300 |
commit | e616d0915c513323affd938f7eb89d23d4e70df5 (patch) | |
tree | c2e7ed2ef10883e8f6ea70f7e5d1d4e59677ef52 | |
parent | 9a422b8984a3ed462a2c35ba97fa8234f3a45591 (diff) | |
download | unit-e616d0915c513323affd938f7eb89d23d4e70df5.tar.gz unit-e616d0915c513323affd938f7eb89d23d4e70df5.tar.bz2 |
Disabled epoll error processing when socket events are inactive.
Diffstat (limited to '')
-rw-r--r-- | src/nxt_epoll_engine.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/nxt_epoll_engine.c b/src/nxt_epoll_engine.c index a944834e..d53df1bc 100644 --- a/src/nxt_epoll_engine.c +++ b/src/nxt_epoll_engine.c @@ -926,6 +926,13 @@ nxt_epoll_poll(nxt_event_engine_t *engine, nxt_msec_t timeout) error = ((events & (EPOLLERR | EPOLLHUP)) != 0); ev->epoll_error = error; + if (error + && ev->read <= NXT_EVENT_BLOCKED + && ev->write <= NXT_EVENT_BLOCKED) + { + error = 0; + } + #if (NXT_HAVE_EPOLL_EDGE) ev->epoll_eof = ((events & EPOLLRDHUP) != 0); |