summaryrefslogtreecommitdiff
path: root/louloulibs/network/dns_socket_handler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'louloulibs/network/dns_socket_handler.cpp')
-rw-r--r--louloulibs/network/dns_socket_handler.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/louloulibs/network/dns_socket_handler.cpp b/louloulibs/network/dns_socket_handler.cpp
index 5fd08cb..403a5be 100644
--- a/louloulibs/network/dns_socket_handler.cpp
+++ b/louloulibs/network/dns_socket_handler.cpp
@@ -42,7 +42,8 @@ bool DNSSocketHandler::is_connected() const
void DNSSocketHandler::remove_from_poller()
{
- this->poller->remove_socket_handler(this->socket);
+ if (this->poller->is_managing_socket(this->socket))
+ this->poller->remove_socket_handler(this->socket);
}
#endif /* CARES_FOUND */