| [ Web Proxy ] |
| Viewing: https://raw.githubusercontent.com/lqlstudio/netkiller.github.io/master/python/../python/popen.html | [Back] [Original] |
#!/usr/bin/python
from subprocess import *
p = Popen(["cat", "-n"], bufsize=1024,stdin=PIPE,
stdout=PIPE, close_fds=True)
(fin, fout) = (p.stdin, p.stdout)
for i in range(10):
fin.write("line" + str(i))
fin.write('\n')
fin.flush()
print fout.readline(),
| Web Proxy Viewer | New URL | Original Page |