better support for KeyboardInterrupt exceptions

This commit is contained in:
Mike Fährmann
2015-04-10 17:31:49 +02:00
parent 1cd25b5369
commit 5806e02f97
2 changed files with 6 additions and 4 deletions

View File

@@ -54,5 +54,8 @@ def main():
conf = parse_config_file(opts.config)
dlmgr = DownloadManager(opts, conf)
for url in opts.urls:
dlmgr.add(url)
try:
for url in opts.urls:
dlmgr.add(url)
except KeyboardInterrupt:
print("KeyboardInterrupt")