Pastebin

Paste #467: dup2

< previous paste - next paste>

Pasted by Morten

Download View as text

                p = Popen([scriptfile], shell=True, stdin=PIPE, stdout=PIPE, close_fds=True)
                (child_stdout, child_stdin) = (p.stdout, p.stdin)
                print "Executing os.dup2"
                os.dup2(child_stdin.fileno(), 0)
                os.dup2(child_stdout.fileno(), 1)

New Paste


Do not write anything in this field if you're a human.

Go to most recent paste.