[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Monotone-devel] Performance improvement splitout

From: Zack Weinberg
Subject: [Monotone-devel] Performance improvement splitout
Date: Mon, 18 Sep 2006 12:01:13 -0700

[this was meant to go to the list, sorry Tim]

On 9/18/06, Timothy Brownawell <address@hidden> wrote:
On Mon, 2006-09-18 at 11:08 -0700, Eric Anderson wrote:
> It's a probe to see whether any "Error" data has arrived, which near
> as I can tell included data sent over TCP with urgency.  When I went
> searching for something that used it, I recall finding that the usher
> code seemed to use this as a "something bad happened, go die now."
> It's been a long time since I looked at this though.

Um... that's probably a bad place to look, I just had it do what the
example in select_tut(2) (and also IIRC monotone) did.

Now that I know slightly more I'm fairly sure we can just not use that
(give select() an empty FD_SET for that argument), since we never send
OOB/high-priority data. But if we do look at it, killing the connection
is probably a good response since we're receiving something we know the
other side didn't send...

It seems to me that it would be adequate defensiveness if, when (and
only when) we are going to select() for read or write on a socket, we
also select for errors on that socket, and handle any sockets tagged
in the error set appropriately.  Note that I *think* things like TCP
RST packets get reported that way; it's not just for MSG_OOB / TCP


reply via email to

[Prev in Thread] Current Thread [Next in Thread]