diff --git a/modules/s_dns_resolver.cc b/modules/s_dns_resolver.cc index c81709a41..2ddc7b770 100644 --- a/modules/s_dns_resolver.cc +++ b/modules/s_dns_resolver.cc @@ -134,22 +134,23 @@ noexcept if(ns.is_open()) ns.close(); - timeout_context.terminate(); - sendq_context.terminate(); - recv_context.terminate(); done.wait([this] { const bool ret(tags.empty()); - if(!ret) log::warning { - log, "Waiting for %zu unfinished DNS resolutions", tags.size() + log, "Waiting for %zu unfinished DNS resolutions", + tags.size() }; return ret; }); + timeout_context.terminate(); + sendq_context.terminate(); + recv_context.terminate(); + assert(tags.empty()); }