diff options
author | Guido van Rossum <guido@python.org> | 2002-08-08 15:25:28 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2002-08-08 15:25:28 (GMT) |
commit | de7cadec54f6c67f65c35df8b5df5233ab9eb97c (patch) | |
tree | 79a61ed4ea7e932b6ea2c6fcc700cc2f6210c882 /Lib/socket.py | |
parent | 7c3b6347e5e4db0d89e9acfa7a66910a15feffd2 (diff) | |
download | cpython-de7cadec54f6c67f65c35df8b5df5233ab9eb97c.zip cpython-de7cadec54f6c67f65c35df8b5df5233ab9eb97c.tar.gz cpython-de7cadec54f6c67f65c35df8b5df5233ab9eb97c.tar.bz2 |
Extend __all__ with the exports list of the _ssl module.
Diffstat (limited to 'Lib/socket.py')
-rw-r--r-- | Lib/socket.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Lib/socket.py b/Lib/socket.py index b9e36da..6c39d76 100644 --- a/Lib/socket.py +++ b/Lib/socket.py @@ -45,6 +45,7 @@ from _socket import * _have_ssl = False try: + import _ssl from _ssl import * _have_ssl = True except ImportError: @@ -54,7 +55,8 @@ import os, sys __all__ = ["getfqdn"] __all__.extend(os._get_exports_list(_socket)) -# XXX shouldn't there be something similar to the above for _ssl exports? +if _have_ssl: + __all__.extend(os._get_exports_list(_ssl)) _realsocket = socket _needwrapper = False @@ -90,6 +92,7 @@ if sys.platform.lower().startswith("win"): errorTab[10064] = "The host is down." errorTab[10065] = "The host is unreachable." __all__.append("errorTab") + del os, sys |