dont throw exception for invalid files
This commit is contained in:
parent
75e0ec06f9
commit
f02d42712d
1 changed files with 58 additions and 55 deletions
|
@ -219,6 +219,9 @@ def ffprobe(filename):
|
|||
return value
|
||||
|
||||
info = {}
|
||||
if not 'format' in ffinfo:
|
||||
info['error'] = 'badfile'
|
||||
else:
|
||||
for key in ('duration', 'size', 'bit_rate'):
|
||||
info[{
|
||||
'bit_rate': 'bitrate'
|
||||
|
|
Loading…
Reference in a new issue