From 157852ce99ba6f142774f12a4d5b2f950a87b756 Mon Sep 17 00:00:00 2001 From: Christopher Faulet Date: Mon, 15 Sep 2025 07:57:28 +0200 Subject: [PATCH] BUG/MEDIUM: resolvers: Wake resolver task up whne unlinking a stream requester Another regression introduced with the commit 3023e9819 ("BUG/MINOR: resolvers: Restore round-robin selection on records in DNS answers"). Stream requesters are unlinked from any theards. So we must not try to queue the resolver's task here because it is not allowed to do so from another thread than the task thread. Instead, we can simply wake the resolver's task up. It is only performed when the last stream requester is unlink from the resolution. This patch should fix the issue #3119. It must be backported with the commit above. --- src/resolvers.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/resolvers.c b/src/resolvers.c index 0a424cf7c..9306996f4 100644 --- a/src/resolvers.c +++ b/src/resolvers.c @@ -2227,7 +2227,7 @@ static void _resolv_unlink_resolution(struct resolv_requester *requester) else { if (!tick_isset(res->last_resolution)) res->last_resolution = now_ms; - resolv_update_resolvers_timeout(res->resolvers); + task_wakeup(res->resolvers->t, TASK_WOKEN_OTHER); } return; }