close_fds

This commit is contained in:
j 2015-04-24 18:39:16 +02:00
parent f814049805
commit 5654d47b58
1 changed files with 4 additions and 2 deletions

View File

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