Merge pull request #492 from public/py-thread-safe

Python implementation of OpenSSL locking callback