event/Loop: manage all SocketEvents in a linked list

Not only those which are "ready".
This commit is contained in:
Max Kellermann
2020-10-18 19:39:21 +02:00
parent dd94f97572
commit a14997ffb8
4 changed files with 33 additions and 20 deletions
+1 -1
View File
@@ -69,7 +69,7 @@ SocketEvent::Schedule(unsigned flags) noexcept
if (scheduled_flags == 0)
success = loop.AddFD(fd.Get(), flags, *this);
else if (flags == 0)
success = loop.RemoveFD(fd.Get());
success = loop.RemoveFD(fd.Get(), *this);
else
success = loop.ModifyFD(fd.Get(), flags, *this);