Nate Smith
3/10/2006 6:29:00 AM
Sorry, the code should look like:
server = TCPServer.new( '127.0.0.1', 31337 )
socket = server.accept
data = socket.gets # added this line
# now client (via telnet), sends control-c
socket.print "test" # <-- produces no output on client
On Mar 9, 2006, at 10:10 PM, Nate Smith wrote:
> Hello,
>
> I created a server, accepted a connection via telnet, and if the
> client sends a control-c, the TCPSocket hangs. It can still read
> data, but writing to it produces no output on the client side.
> Here's the code:
>
> server = TCPServer.new( '127.0.0.1', 31337 )
> socket = server.accept
>
> # now client (via telnet), sends control-c
>
> socket.print "test" # <-- produces no output on client
>
> Anyone know what's up? I checked for exception throws and there are
> none, and the server side keeps running normally, besides this.
>
> Nate
>