event/SocketEvent: move Dispatch() down
This commit is contained in:
parent
7901b04c78
commit
7fc04fd5cd
|
@ -28,16 +28,6 @@
|
|||
#include <cerrno>
|
||||
#endif
|
||||
|
||||
void
|
||||
SocketEvent::Dispatch() noexcept
|
||||
{
|
||||
const unsigned flags = std::exchange(ready_flags, 0) &
|
||||
(GetScheduledFlags() | IMPLICIT_FLAGS);
|
||||
|
||||
if (flags != 0)
|
||||
callback(flags);
|
||||
}
|
||||
|
||||
void
|
||||
SocketEvent::Open(SocketDescriptor _fd) noexcept
|
||||
{
|
||||
|
@ -99,3 +89,13 @@ SocketEvent::Schedule(unsigned flags) noexcept
|
|||
|
||||
return success;
|
||||
}
|
||||
|
||||
void
|
||||
SocketEvent::Dispatch() noexcept
|
||||
{
|
||||
const unsigned flags = std::exchange(ready_flags, 0) &
|
||||
(GetScheduledFlags() | IMPLICIT_FLAGS);
|
||||
|
||||
if (flags != 0)
|
||||
callback(flags);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue