[issue3890] ssl.SSLSocket.recv() implementation may not work with non-blocking sockets

Giampaolo Rodola' report at bugs.python.org
Mon Mar 22 09:22:41 CET 2010


Giampaolo Rodola' <billiejoex at users.sourceforge.net> added the comment:

> The intuitive explanation seems to be:
> - there are some bytes available for reading on the *TCP socket*, 
> therefore asyncore calls the read handler
> - however, there are not enough bytes for OpenSSL to actually decrypt 
> any data, which is why we get SSL_ERROR_WANT_READ when trying to read 
> from the *SSL socket*
> The following patch seems to fix test_ftplib; any thoughts?

The patch seems ok to me. This is how it was supposed to be in the first place if ssl.py behaved as expected with non blocking sockets.

----------

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


More information about the Python-bugs-list mailing list