diff Lib/socket.py @ 29465:1e2e54821785 legacy-trunk

Always unwrap _socketobj in socket.ssl. Revert httplib.py 1.25. Fixes #754447.
author Martin v. Löwis <martin@v.loewis.de>
date Sat, 14 Jun 2003 13:30:53 +0000
parents ed70779f6402
children a910b822b12c
line wrap: on
line diff
--- a/Lib/socket.py	Sat Jun 14 13:11:24 2003 +0000
+++ b/Lib/socket.py	Sat Jun 14 13:30:53 2003 +0000
@@ -65,16 +65,12 @@
     __all__.extend(os._get_exports_list(_ssl))
 
 _realsocket = socket
-if (sys.platform.lower().startswith("win")
-    or (hasattr(os, 'uname') and os.uname()[0] == "BeOS")
-    or sys.platform=="riscos"):
-
-    if _have_ssl:
-        _realssl = ssl
-        def ssl(sock, keyfile=None, certfile=None):
-            if hasattr(sock, "_sock"):
-                sock = sock._sock
-            return _realssl(sock, keyfile, certfile)
+if _have_ssl:
+    _realssl = ssl
+    def ssl(sock, keyfile=None, certfile=None):
+        if hasattr(sock, "_sock"):
+            sock = sock._sock
+        return _realssl(sock, keyfile, certfile)
 
 # WSA error codes
 if sys.platform.lower().startswith("win"):