diff options
| author | tassaron | 2017-08-28 18:54:54 -0400 |
|---|---|---|
| committer | tassaron | 2017-08-28 18:54:54 -0400 |
| commit | 8411857030d92e448d5c64682f396e677161afbe (patch) | |
| tree | 2dc5e033a4073d433aaa824113467032d35ca3c1 /src/video_thread.py | |
| parent | ad6dd9f5329f3e23e75c181c21ca8701028b538f (diff) | |
ctrl-c ends commandline mode properly
Diffstat (limited to 'src/video_thread.py')
| -rw-r--r-- | src/video_thread.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/video_thread.py b/src/video_thread.py index 823ac73..91ebe93 100644 --- a/src/video_thread.py +++ b/src/video_thread.py @@ -252,9 +252,14 @@ class Worker(QtCore.QObject): print('############################') log.info('Opening pipe to ffmpeg') log.info(cmd) - self.out_pipe = openPipe( - ffmpegCommand, stdin=sp.PIPE, stdout=sys.stdout, stderr=sys.stdout - ) + try: + self.out_pipe = openPipe( + ffmpegCommand, + stdin=sp.PIPE, stdout=sys.stdout, stderr=sys.stdout + ) + except sp.CalledProcessError: + log.critical('Ffmpeg pipe couldn\'t be created!') + raise # =~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~=~==~=~=~=~=~=~=~=~=~=~=~=~=~=~ # START CREATING THE VIDEO |
