projects
/
vidi-player.git
/ blobdiff
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Handle KeyboardInterrupt in the main program, not in the Player class
[vidi-player.git]
/
vidi-player.py
diff --git
a/vidi-player.py
b/vidi-player.py
index
04c8941
..
62ae575
100755
(executable)
--- a/
vidi-player.py
+++ b/
vidi-player.py
@@
-105,7
+105,11
@@
def main():
if len(sys.argv) > 3:
timeline.save(sys.argv[3])
else:
- timeline.play()
+ try:
+ timeline.play()
+ except KeyboardInterrupt:
+ timeline.stop()
+ return 1
if __name__ == "__main__":