projects
/
ffpreview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9c18959
)
* Count errors in batch mode.
author
Urban Wallasch
<urban.wallasch@freenet.de>
Thu, 13 May 2021 08:55:49 +0000
(10:55 +0200)
committer
Urban Wallasch
<urban.wallasch@freenet.de>
Thu, 13 May 2021 08:55:49 +0000
(10:55 +0200)
ffpreview.py
patch
|
blob
|
history
diff --git
a/ffpreview.py
b/ffpreview.py
index e71c4112bf2818d0b334e1add2eb3457c3630fbe..74de7d59d6f8c3a7188fe0b452c3711de9cf32ad 100755
(executable)
--- a/
ffpreview.py
+++ b/
ffpreview.py
@@
-947,12
+947,14
@@
def main():
signal.signal(signal.SIGPIPE, signal.SIG_IGN)
if cfg['batch']:
+ errcnt = 0
if isinstance(cfg['vid'], list):
for fn in cfg['vid']:
- ok = batch_process(fn)
- else:
- ok = batch_process(cfg['vid'])
- exit(0 if ok else 3)
+ if not batch_process(fn):
+ errcnt += 1
+ elif not batch_process(cfg['vid']):
+ errcnt += 1
+ exit(errcnt)
if isinstance(cfg['vid'], list):
eprint(0, 'Only using first file in interactive mode.')