1
0
mirror of https://github.com/mikf/gallery-dl.git synced 2024-11-25 04:02:32 +01:00

fix issue with Ctrl+c on windows

This commit is contained in:
Mike Fährmann 2015-12-02 01:01:33 +01:00
parent 140f0475a6
commit a8c0b4531d
No known key found for this signature in database
GPG Key ID: 5680CA389D365A88

View File

@ -11,7 +11,7 @@
import os
class BasicDownloader():
"""Base class for downlaoder modules"""
"""Base class for downloader modules"""
max_tries = 5
@ -21,7 +21,8 @@ class BasicDownloader():
try:
return self.download_impl(url, file)
except:
# make sure to remove file if download failed
#remove file if download failed
file.close()
os.unlink(path)
raise