From mboxrd@z Thu Jan 1 00:00:00 1970 To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> In-reply-to: Your message of "Thu, 17 Apr 2008 15:29:42 EDT." <41b9f1bf163c2d3c41e182407477eb28@quanstro.net> From: Bakul Shah Date: Thu, 17 Apr 2008 14:42:30 -0700 Message-Id: <20080417214230.899775B4A@mail.bitblocks.com> Subject: Re: [9fans] telnet vs. godaddy whois Topicbox-Message-UUID: 914ff408-ead3-11e9-9d60-3106f5b1d025 On Thu, 17 Apr 2008 15:29:42 EDT erik quanstrom wrote: > > On Thu, 17 Apr 2008 09:18:31 BST Charles Forsyth w > rote: > >> > having said that, i now suspect that sending one byte into a zero-window > is > >> not the problem. > >> > >> because the one-byte probe can only be done if there is data to send, and > i > >> already knew that a plain connection (dial only) to that port also failed: > > > > Not setting the PSH bit on a pure ACK (== no data is being > > sent) seems to fix this (see ip/tcp.c around line 2530). May > > be it tickles a bug on the receiver (0 byte read?). > > this does work for me. is there some subtile reason *to* set the psh bit > on a pure ack? in certain circumstances? While I wouldn't call it "wrong" it seems silly to set the PSH bit when no data is being sent. See rfc1122 section 4.2.2.2. Among other things it says: At the receiver, the PSH bit forces buffered data to be delivered to the application (even if less than a full buffer has been received). Because of this what is likely happening is that on receiving the PSH bit read() completes and returns to the caller app with a count = 0 which the app must think indicates EOF! May be this behavior in plan9 is due to a misplaced right brace? Move the closing brace on line 2530 to below the PSH bit logic and all is fine.