From 5cefce99224ef7b9b35546597344d4e888e3e6fd Mon Sep 17 00:00:00 2001 From: "dg@cowlark.com" Date: Mon, 27 Mar 2023 21:06:59 +0000 Subject: [PATCH] Fix the thread termination errors every time the directory browser is used. --- src/gui/main.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/main.cc b/src/gui/main.cc index 854f0c35..8073312e 100644 --- a/src/gui/main.cc +++ b/src/gui/main.cc @@ -93,7 +93,7 @@ void FluxEngineApp::RunOnWorkerThread(std::function callback) std::cerr << "Cannot start new worker task as one is already running\n"; _callback = callback; - if (GetThread()) + if (GetThread() && GetThread()->IsRunning()) GetThread()->Wait(); emergencyStop = false;