diff options
author | Jean-Paul Calderone <exarkun@divmod.com> | 2010-08-11 22:41:49 -0400 |
---|---|---|
committer | Jean-Paul Calderone <exarkun@divmod.com> | 2010-08-11 22:41:49 -0400 |
commit | 297294ef009efa1b39d888c0eb28885185fb9635 (patch) | |
tree | c3e7267ec54632c5b698cb9c7e3d2478dc44999e /OpenSSL/__init__.py | |
parent | e628465b01666d1c8ea8cdaca39197fd970b3485 (diff) | |
download | pyopenssl-297294ef009efa1b39d888c0eb28885185fb9635.tar.gz |
Hack up module import like mad
This is a workaround for the loss of PyCObject
Diffstat (limited to 'OpenSSL/__init__.py')
-rw-r--r-- | OpenSSL/__init__.py | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/OpenSSL/__init__.py b/OpenSSL/__init__.py index 6f393ff..e88b141 100644 --- a/OpenSSL/__init__.py +++ b/OpenSSL/__init__.py @@ -8,5 +8,16 @@ """ pyOpenSSL - A simple wrapper around the OpenSSL library """ -import rand, crypto, SSL, tsafe -from version import __version__ + +import sys +orig = sys.getdlopenflags() +sys.setdlopenflags(2|256) +from OpenSSL import crypto +sys.setdlopenflags(orig) +del sys, orig + +from OpenSSL import rand, SSL, tsafe +from OpenSSL.version import __version__ + +__all__ = [ + 'rand', 'crypto', 'SSL', 'tsafe', '__version__'] |