]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Disable dup() of SSLSocket. I don't think it can be made to work.
authorGuido van Rossum <guido@python.org>
Fri, 16 Nov 2007 01:28:45 +0000 (01:28 +0000)
committerGuido van Rossum <guido@python.org>
Fri, 16 Nov 2007 01:28:45 +0000 (01:28 +0000)
Lib/ssl.py

index 9d63d12ce3babfbf2e40329d885fd089e804d300..0161efaa992a1e0f2c54f2880d631d88bccf4d7c 100644 (file)
@@ -140,6 +140,10 @@ class SSLSocket(socket):
         self.do_handshake_on_connect = do_handshake_on_connect
         self.suppress_ragged_eofs = suppress_ragged_eofs
 
+    def dup(self):
+        raise NotImplemented("Can't dup() %s instances" %
+                             self.__class__.__name__)
+
     def _checkClosed(self, msg=None):
         # raise an exception here if you wish to check for spurious closes
         pass