Author irmen
Recipients
Date 2005-01-13.22:59:31
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Logged In: YES 
user_id=129426

(confirmed on Python 2.4 and HEAD)

But: your analysis is not correct:
internal_select doesn't return with timeout==1 when a SIGINT
occurs, instead it returns 0, because it doesn't check for
an error condition that select() may return.

So I hacked around a bit and changed internal_select to
return -1 when the select() system call returns -1,
and then also added the following in sock_recv:

if(errno) {
   Py_DECREF(buf);
   return PyErr_SetFromErrno(socket_error);
}

Which seems to make the example script that is attached to
this bug report run as expected.

As you say, I also think that this check must be added at
all locations where internal_select is called.

What do you say? I can make a patch if this is okay.
History
Date User Action Args
2007-08-23 14:20:43adminlinkissue926423 messages
2007-08-23 14:20:43admincreate