diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2007-10-21 19:24:09 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2007-10-21 19:24:09 +0000 |
commit | 0c04ea89dbb1516423535b2f5fdadbdab9fe8e58 (patch) | |
tree | 7d599b208f24869822cc1c619a3de755852e0e34 /src/socketengine_epoll.cpp | |
parent | 32bffd861fd1c8b723ae63f4ea66720fd47e7d0a (diff) |
Set these back to sane operation
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8271 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/socketengine_epoll.cpp')
-rw-r--r-- | src/socketengine_epoll.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/socketengine_epoll.cpp b/src/socketengine_epoll.cpp index df79aa083..ec5362f8c 100644 --- a/src/socketengine_epoll.cpp +++ b/src/socketengine_epoll.cpp @@ -49,7 +49,7 @@ bool EPollEngine::AddFd(EventHandler* eh) return false; if (ref[fd]) - DelFd(ref[fd]); + return false; struct epoll_event ev; memset(&ev,0,sizeof(struct epoll_event)); @@ -86,9 +86,6 @@ bool EPollEngine::DelFd(EventHandler* eh, bool force) if ((fd < 0) || (fd > MAX_DESCRIPTORS)) return false; - ref[fd] = NULL; - CurrentSetSize--; - struct epoll_event ev; memset(&ev,0,sizeof(struct epoll_event)); eh->Readable() ? ev.events = EPOLLIN : ev.events = EPOLLOUT; @@ -101,6 +98,9 @@ bool EPollEngine::DelFd(EventHandler* eh, bool force) return false; } + ref[fd] = NULL; + CurrentSetSize--; + ServerInstance->Log(DEBUG,"Remove file descriptor: %d", fd); return true; } |