From: Yohanes Santoso Date: 2005-07-01T12:10:58+09:00 Subject: Re: stupid TCP "Ryan Leavengood" writes: > Joe Van Dyk said: >> >> Aha. I'm guessing it has something to do with not sending the data >> immediately. If I do >> >> tcp_client.close >> >> Then the data gets sent. But I don't want to close the socket. And >> I'm not seeing anything (yet) that would let me immediately send (I >> tried IO#flush) the data over the socket. > > From what I've seen the problem is on the reading end, not the writing > end. Try just doing Joe, Just another thing to note: in TCP, the TCP stack is free to send the data on the wire whenever it wants to. You can't force it, although in most TCP stack implementations, a flush() is persuasive enough. If you want a more guaranteed way of putting data on the wire whenever you want it, you'd have to use other protocols, like UDP. YS.