odbus/Watch: use SocketEvent::ReleaseSocket() to allow another Open()
This commit is contained in:
parent
65473b5113
commit
ed1caffc79
@ -54,7 +54,7 @@ DbusToLibevent(unsigned flags) noexcept
|
||||
void
|
||||
WatchManager::Watch::Toggled() noexcept
|
||||
{
|
||||
event.Cancel();
|
||||
event.ReleaseSocket();
|
||||
|
||||
if (dbus_watch_get_enabled(&watch)) {
|
||||
event.Open(SocketDescriptor(dbus_watch_get_unix_fd(&watch)));
|
||||
|
Loading…
Reference in New Issue
Block a user