From 80b8bdc6405e91c91642d0c05b0c755f8670dbe2 Mon Sep 17 00:00:00 2001 From: Gunnar Beutner Date: Tue, 9 Feb 2016 12:46:11 +0100 Subject: [PATCH] Fix: Cluster WQ thread dies after fork() fixes #11118 --- lib/remote/apilistener.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/remote/apilistener.cpp b/lib/remote/apilistener.cpp index 6d4e5871f..77049f71d 100644 --- a/lib/remote/apilistener.cpp +++ b/lib/remote/apilistener.cpp @@ -566,6 +566,9 @@ void ApiListener::ApiTimerHandler(void) void ApiListener::RelayMessage(const MessageOrigin::Ptr& origin, const ConfigObject::Ptr& secobj, const Dictionary::Ptr& message, bool log) { + if (!IsActive()) + return; + m_RelayQueue.Enqueue(boost::bind(&ApiListener::SyncRelayMessage, this, origin, secobj, message, log), PriorityNormal, true); }