[downloader] Remove resume file after installation finishes

This commit is contained in:
derrod 2020-04-18 02:17:46 +02:00
parent 0b2917d1eb
commit feed5735d4

View file

@ -597,6 +597,12 @@ class DLManager(Process):
if t.is_alive(): if t.is_alive():
self.log.warning(f'Thread did not terminate! {repr(t)}') self.log.warning(f'Thread did not terminate! {repr(t)}')
# clean up resume file
try:
os.remove(self.resume_file)
except OSError as e:
self.log.warning(f'Failed to remove resume file: {e!r}')
# close up shared memory # close up shared memory
self.shared_memory.close() self.shared_memory.close()
self.shared_memory.unlink() self.shared_memory.unlink()