1
0
mirror of https://github.com/spaam/svtplay-dl.git synced 2024-11-27 21:54:17 +01:00

We should catch KeyboardInterrupt in __init__.py

We don't catch it if someone install it via setup.py with the old fix.
This commit is contained in:
Johan Andersson 2014-04-02 19:32:35 +02:00
parent 5449e26766
commit fd35357de0
2 changed files with 6 additions and 5 deletions

View File

@ -195,4 +195,8 @@ def main():
sys.exit(4)
url = args[0]
get_media(url, options)
try:
get_media(url, options)
except KeyboardInterrupt:
pass

View File

@ -8,10 +8,7 @@ if __package__ is None and not hasattr(sys, "frozen"):
import os.path
sys.path.append(os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
try:
import svtplay_dl
if __name__ == '__main__':
svtplay_dl.main()
except KeyboardInterrupt:
pass
svtplay_dl.main()