Fix regression introduced by 08e4b076be
.
This commit is contained in:
parent
8e6699bb5c
commit
a1dfe48870
@ -313,17 +313,18 @@ final class EpollEventLoop extends SingleThreadEventLoop {
|
|||||||
if (ch != null) {
|
if (ch != null) {
|
||||||
AbstractEpollUnsafe unsafe = (AbstractEpollUnsafe) ch.unsafe();
|
AbstractEpollUnsafe unsafe = (AbstractEpollUnsafe) ch.unsafe();
|
||||||
|
|
||||||
// First check if EPOLLIN was set, in this case we do not need to check for
|
// First check if EPOLLRDHUP was set, this will notify us for connection-reset in which case
|
||||||
// EPOLLRDHUP as EPOLLIN will handle connection-reset case as well.
|
// we may close the channel directly or try to read more data depending on the state of the
|
||||||
if ((ev & Native.EPOLLIN) != 0) {
|
// Channel and als depending on the AbstractEpollChannel subtype.
|
||||||
// Something is ready to read, so consume it now
|
if ((ev & Native.EPOLLRDHUP) != 0) {
|
||||||
unsafe.epollInReady();
|
|
||||||
} else if ((ev & Native.EPOLLRDHUP) != 0) {
|
|
||||||
unsafe.epollRdHupReady();
|
unsafe.epollRdHupReady();
|
||||||
}
|
}
|
||||||
|
if ((ev & Native.EPOLLIN) != 0 && ch.isOpen()) {
|
||||||
|
// The Channel is still open and there is something to read. Do it now.
|
||||||
|
unsafe.epollInReady();
|
||||||
|
}
|
||||||
if ((ev & Native.EPOLLOUT) != 0 && ch.isOpen()) {
|
if ((ev & Native.EPOLLOUT) != 0 && ch.isOpen()) {
|
||||||
// force flush of data as the epoll is writable again
|
// Force flush of data as the epoll is writable again
|
||||||
unsafe.epollOutReady();
|
unsafe.epollOutReady();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
Reference in New Issue
Block a user