[ffmpeg] use subprocess.check_call

This fixes RuntimeError: No active exception to reraise
This commit is contained in:
lilydjwg 2015-09-27 16:38:38 +08:00
parent 5eb9cebe4e
commit acda697f54

View File

@ -109,11 +109,9 @@ def ffmpeg_concat_flv_to_mp4(files, output='output.mp4'):
params.append(output + '.txt')
params += ['-c', 'copy', output]
if subprocess.call(params) == 0:
os.remove(output + '.txt')
return True
else:
raise
subprocess.check_call(params)
os.remove(output + '.txt')
return True
for file in files:
if os.path.isfile(file):