remove tmp file when closing app with signal sigterm or sigint
This commit is contained in:
@@ -42,6 +42,7 @@ class LogFileModel:
|
||||
|
||||
with self._lock:
|
||||
# TODO handle lines longer than 4096 bytes
|
||||
# TODO abort file open after a few secons: https://docs.python.org/3/library/signal.html#example
|
||||
with open(self._file, 'rb') as f:
|
||||
offset = min(byte_offset, self.byte_count())
|
||||
offset = max(0, offset - self.settings.max_line_length())
|
||||
|
||||
Reference in New Issue
Block a user