Close child fds when using subprocess
This commit is contained in:
parent
dfd0cc947b
commit
9947c7e0cd
@ -34,7 +34,8 @@ def _doRunCommand(command, logger, rundir='/tmp', output=subprocess.PIPE, error=
|
||||
|
||||
logger.info("Running %s" % subprocess.list2cmdline(command))
|
||||
|
||||
p1 = subprocess.Popen(command, cwd=rundir, stdout=output, stderr=error, universal_newlines=True, env=env)
|
||||
p1 = subprocess.Popen(command, cwd=rundir, stdout=output, stderr=error, universal_newlines=True, env=env,
|
||||
close_fds=True)
|
||||
(out, err) = p1.communicate()
|
||||
|
||||
if out:
|
||||
|
Loading…
Reference in New Issue
Block a user