From cfbb1e3fc38898e51ec52b031a797135c5bfa5f6 Mon Sep 17 00:00:00 2001 From: Nicolargo Date: Fri, 1 Apr 2016 14:17:34 +0200 Subject: [PATCH] Extension of log file is not good when a previous one exist --- glances/logger.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/glances/logger.py b/glances/logger.py index f7936444..98086ba6 100644 --- a/glances/logger.py +++ b/glances/logger.py @@ -88,7 +88,7 @@ def tempfile_name(): ret = os.path.join(tempfile.gettempdir(), 'glances.log') if os.access(ret, os.F_OK) and not os.access(ret, os.W_OK): print("WARNING: Couldn't write to log file {0} (Permission denied)".format(ret)) - ret = tempfile.mkstemp(prefix='glances', suffix='.tmp', text=True) + ret = tempfile.mkstemp(prefix='glances', suffix='.log', text=True) print("Create a new log file: {0}".format(ret[1])) return ret[1]