[Toybox] [PATCH] netcat: make -l exit after handling a request
Josh Gao
jmgao at google.com
Fri Jun 9 14:22:38 PDT 2017
On Fri, Jun 9, 2017 at 1:31 PM, Rob Landley <rob at landley.net> wrote:
> On 06/09/2017 01:05 PM, Josh Gao wrote:
> > Patch attached.
>
> What specifically did you fix? (I.E. is this the same "netcat -L
> zombies" issue I have on my todo list?)
>
This makes `nc -l` do what it says it does, and listen for exactly one
connection before exiting, instead of handling connections until a ^C.
terminal1$ echo foo | toybox nc -l -p 1234 > bar
terminal1$ cat bar
bar
terminal2$ echo bar | toybox nc localhost 1234 > foo
terminal2$ cat foo
foo
(Unrelated: is matching the BSD netcat's command line interface a goal? I
keep
accidentally doing `toybox nc -l 1234` and getting bitten by it.)
I'm -> <- this close to getting a release out, the only issue left after
> dmesg is fixing the help text generator, lemme do that, cut a release,
> and _then_ dive into this. :)
>
Sure, thanks :-)
-Josh
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.landley.net/pipermail/toybox-landley.net/attachments/20170609/136e2bd3/attachment-0002.htm>
More information about the Toybox
mailing list