From 96953744c9e352991347f0166a31338c6d50ef78 Mon Sep 17 00:00:00 2001 From: Athanasius Date: Fri, 16 Oct 2020 15:54:13 +0100 Subject: [PATCH] monitor: Close journal loghandle if signalled to close down. --- monitor.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/monitor.py b/monitor.py index e9af7328..9aecfe92 100644 --- a/monitor.py +++ b/monitor.py @@ -384,6 +384,9 @@ class EDLogs(FileSystemEventHandler): # type: ignore # See below # Check whether we're still supposed to be running if threading.current_thread() != self.thread: logger.info("We're not meant to be running, exiting...") + if loghandle: + loghandle.close() + return # Terminate if self.game_was_running: