[New-bugs-announce] [issue8831] recv and recvfrom on UDP socket do not return/throw exception after a close()

Alessandro Roat report at bugs.python.org
Thu May 27 10:43:14 CEST 2010


New submission from Alessandro Roat <alexroat at gmail.com>:

A thread blocked on a recv or a recvfrom method on a UDP socket (waiting for a datagram) can not be unlocked calling a .close() from a different thread.
This is in contrast with the standard C++/C behavior, where a close() on a socket causes an asynchronous and immediate exception/return with error on the functions that are using the socket at the same time (but in another thread).
Thus, it is impossible to unlock a waiting recv/recvfrom calling a close() or a shutdown() if no more datagrams are coming.

----------
components: IO
messages: 106596
nosy: Alessandro.Roat
priority: normal
severity: normal
status: open
title: recv and recvfrom on UDP socket do not return/throw exception after a close()
type: behavior
versions: Python 2.6

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue8831>
_______________________________________


More information about the New-bugs-announce mailing list