From 2e65a35cd7a36fe003998adde7a087736a0582dc Mon Sep 17 00:00:00 2001 From: Andreas Karlson Date: Wed, 10 Apr 2024 14:44:22 +0200 Subject: [PATCH] scheduler: Fix regression in background thread (Issue #934) The con->bg_pending value is used to indicate that the background thread has finished running and that the connection can be safely closed. This commit makes the con->bg_pending = 0 only after the connection can be safely closed. --- scheduler/ipp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scheduler/ipp.c b/scheduler/ipp.c index 7a8148411c..37623c54ec 100644 --- a/scheduler/ipp.c +++ b/scheduler/ipp.c @@ -5517,10 +5517,10 @@ create_local_bg_thread( ippDelete(response); - con->bg_pending = 0; - send_response(con); + con->bg_pending = 0; + return (NULL); } -- 2.47.2