[issue27629] Cannot create ssl.SSLSocket without existing socket

Christian Heimes report at bugs.python.org
Wed Sep 7 07:43:21 EDT 2016


Christian Heimes added the comment:

The patch is incomplete. Please also check that type == SOCK_STREAM. The code can be simplified with a bitmask test:

if sock is not None:
    type = sock.type
if type & socket.SOCK_STREAM != socket.SOCK_STREAM:
    raise NotImplementedError

----------

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


More information about the Python-bugs-list mailing list