8000 Fix subprocess_attach_write_pipe example · python/asyncio@eec5196 · GitHub
[go: up one dir, main page]

Skip to content
This repository was archived by the owner on Nov 23, 2017. It is now read-only.

Commit eec5196

Browse files
committed
Fix subprocess_attach_write_pipe example
Close the transport, not directly the pipe.
1 parent ab5d83c commit eec5196

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/subprocess_attach_write_pipe.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ def task():
2929

3030
stdout, stderr = yield from proc.communicate()
3131
print("stdout = %r" % stdout.decode())
32-
pipe.close()
32+
transport.close()
3333

3434
loop.run_until_complete(task())
3535
loop.close()

0 commit comments

Comments
 (0)
0