summaryrefslogtreecommitdiffstats
path: root/Doc/lib
diff options
context:
space:
mode:
authorPeter Astrand <astrand@lysator.liu.se>2004-11-30 18:06:42 (GMT)
committerPeter Astrand <astrand@lysator.liu.se>2004-11-30 18:06:42 (GMT)
commit6fdf3cbb13077d44f14251034a31b512ebc9005a (patch)
treed89309df200f469391cb8397544a881490023468 /Doc/lib
parent4871535cfeff41747a0f7b9a3688c49a5df502ad (diff)
downloadcpython-6fdf3cbb13077d44f14251034a31b512ebc9005a.zip
cpython-6fdf3cbb13077d44f14251034a31b512ebc9005a.tar.gz
cpython-6fdf3cbb13077d44f14251034a31b512ebc9005a.tar.bz2
Corrected example for replacing shell pipeline. Fixes bug 1073790.
Diffstat (limited to 'Doc/lib')
-rw-r--r--Doc/lib/libsubprocess.tex2
1 files changed, 1 insertions, 1 deletions
diff --git a/Doc/lib/libsubprocess.tex b/Doc/lib/libsubprocess.tex
index 01f64ae..77bd83e 100644
--- a/Doc/lib/libsubprocess.tex
+++ b/Doc/lib/libsubprocess.tex
@@ -239,7 +239,7 @@ output = Popen(["mycmd", "myarg"], stdout=PIPE).communicate()[0]
output=`dmesg | grep hda`
==>
p1 = Popen(["dmesg"], stdout=PIPE)
-p2 = Popen(["grep", "hda"], stdin=p1.stdout)
+p2 = Popen(["grep", "hda"], stdin=p1.stdout, stdout=PIPE)
output = p2.communicate()[0]
\end{verbatim}