From bd8d612c9fb9e8c172c7cc3eda010d424de7a606 Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Wed, 17 Oct 2018 20:00:59 +0300 Subject: [PATCH] In the MOBILEAPP case, don't set TerminationFlag when there are no sessions The global TerminationFlag is an abomination that has caused lots of trouble when developing the mobile app. The less we use it the better. Here, it gets set elsewhere already when needed; just having no sessions is not reason enough to set it. --- kit/Kit.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/kit/Kit.cpp b/kit/Kit.cpp index 5ea4ad563..1a36b8fe3 100644 --- a/kit/Kit.cpp +++ b/kit/Kit.cpp @@ -2492,11 +2492,13 @@ void lokit_main( { mainKit.poll(SocketPoll::DefaultPollTimeoutMs); +#ifndef MOBILEAPP if (document && document->purgeSessions() == 0) { LOG_INF("Last session discarded. Setting TerminationFlag"); TerminationFlag = true; } +#endif } LOG_INF("Kit poll terminated.");