write stderr to /dev/null, subprocess might block with lots of errors otherwise

This commit is contained in:
j 2015-04-24 18:33:52 +02:00
parent b8cb761dea
commit f814049805

View file

@ -112,7 +112,7 @@ def video(path, height=96, info=None, framerate=FPS):
p = subprocess.Popen(cmd, p = subprocess.Popen(cmd,
bufsize=bufsize, bufsize=bufsize,
stdout=subprocess.PIPE, stdout=subprocess.PIPE,
stderr=subprocess.PIPE) stderr=open('/dev/null', 'w'))
first = True first = True
while True: while True:
@ -151,7 +151,7 @@ def audio(path, info=None, samplerate=48000, framerate=FPS):
p = subprocess.Popen(cmd, p = subprocess.Popen(cmd,
bufsize=bufsize, bufsize=bufsize,
stdout=subprocess.PIPE, stdout=subprocess.PIPE,
stderr=subprocess.PIPE) stderr=open('/dev/null', 'w'))
chunk = int(nbytes / framerate) chunk = int(nbytes / framerate)
first = True first = True