Commit 657043a
committed
keep send side open while receiving in
Netcat likes to close the connection if the receive half is closed by the remote
host, regardless of whether stdin has been closed, and there's no obvious way to
change that behavior. So on the client side we hold both halves open until
we've received something, which matches the p2 example behavior.tcp-p3 example1 parent 6a20a40 commit 657043a
1 file changed
+3
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
72 | | - | |
73 | | - | |
74 | | - | |
| 72 | + | |
75 | 73 | | |
76 | 74 | | |
77 | 75 | | |
78 | 76 | | |
79 | 77 | | |
80 | 78 | | |
81 | | - | |
| 79 | + | |
| 80 | + | |
0 commit comments