summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Lehman <dlehman@redhat.com>2008-10-27 15:38:07 -0500
committerDavid Lehman <dlehman@redhat.com>2008-10-27 15:38:07 -0500
commitd9a79677aa032dd126a9bf84785f4c8943ddd00c (patch)
tree12a3aef773bdb071614607dc6987289e70b482c9
parent98feac5ff9edef234b4e93441617b3d74ed13121 (diff)
downloadanaconda-d9a79677aa032dd126a9bf84785f4c8943ddd00c.tar.gz
anaconda-d9a79677aa032dd126a9bf84785f4c8943ddd00c.tar.xz
anaconda-d9a79677aa032dd126a9bf84785f4c8943ddd00c.zip
Actually use the stderr parameter instead of duping to stdout. (#467289)
execWithCapture takes an argument to specify stderr, but then we ignore it. We just always dupe stderr to stdout. This changes it so that we do what one would expect. If you want stderr duped to stdout, you pass in stderr=1.
-rw-r--r--iutil.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/iutil.py b/iutil.py
index a21cebbdc..d221d9cac 100644
--- a/iutil.py
+++ b/iutil.py
@@ -66,7 +66,7 @@ def execWithCapture(command, argv, stdin = 0, stderr = 2, root='/'):
try:
pipe = subprocess.Popen([command] + argv, stdin=stdin,
stdout=subprocess.PIPE,
- stderr=subprocess.STDOUT,
+ stderr=stderr,
preexec_fn=chroot, cwd=root)
except OSError, (errno, msg):
raise RuntimeError, "Error running " + command + ": " + msg