summaryrefslogtreecommitdiff
path: root/src/socketengines/socketengine_select.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/socketengines/socketengine_select.cpp')
-rw-r--r--src/socketengines/socketengine_select.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/socketengines/socketengine_select.cpp b/src/socketengines/socketengine_select.cpp
index de366266f..f995b5472 100644
--- a/src/socketengines/socketengine_select.cpp
+++ b/src/socketengines/socketengine_select.cpp
@@ -177,7 +177,9 @@ int SelectEngine::DispatchEvents()
if (has_write)
{
WriteEvents++;
- SetEventMask(ev, ev->GetEventMask() & ~(FD_WRITE_WILL_BLOCK | FD_WANT_SINGLE_WRITE));
+ int newmask = (ev->GetEventMask() & ~(FD_WRITE_WILL_BLOCK | FD_WANT_SINGLE_WRITE));
+ this->OnSetEvent(ev, ev->GetEventMask(), newmask);
+ SetEventMask(ev, newmask);
ev->HandleEvent(EVENT_WRITE);
}
}