New submission from Simon Cross <[EMAIL PROTECTED]>: It appears that ssl.SSLSocket attempts to override some of the methods socket.socket delegates to the underlying _socket.socket methods. However, this overriding fails because socket.socket.__init__ replaces all the methods mentioned in _delegate_methods.
These methods are: recv, recvfrom, recv_into, recvfrom_into, send and sendto. ssl.SSLSocket implements recv and send. Neither of these overrides will actually work. ssl.SSLSocket also implements recv_from and send_to which seem to be attempts to override recvfrom and sendto. In the Py3k branch it looks like the overriding done by socket.socket.__init__ is gone so that these methods are now potentially overridable. This could potentially be emulated in trunk by checking for the methods using hasattr(...) before overriding them. I'm happy to create patches which fix the method names and clean up the methods on both branches and add tests. I just want to check that I have an accurate picture of what's needed before starting on them. ---------- components: Library (Lib) messages: 68517 nosy: hodgestar severity: normal status: open title: ssl.SSLSocket implements methods that are overriden by socket.socket.__init__ and methods with incorrect names. versions: Python 2.6, Python 3.0 _______________________________________ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue3162> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com