> I'm seeing a number of malloc (actully, free) errors, now that I'm > pounding on the OpenSSL server/client setup with lots of server > threads and client threads. They all look like either
The issue seems to be that we assume OpenSSL is thread-safe (that is, we call Py_BEGIN_ALLOW_THREADS / Py_END_ALLOW_THREADS), but the _ssl.c code never did what was necessary to support that assumption. See http://www.openssl.org/docs/crypto/threads.html#DESCRIPTION. My analysis is that we need to add lock and unlock functions to the OpenSSL initialization code we currently use, which looks like this: /* Init OpenSSL */ SSL_load_error_strings(); SSLeay_add_ssl_algorithms(); Or, just not allow threads, which seems wrong. Bill _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com