diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2010-05-16 19:56:32 (GMT) |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2010-05-16 19:56:32 (GMT) |
commit | 65ec8ae47fa4bb0a3c2ef815ca1b03f3519398bc (patch) | |
tree | b7cc83b7967ae302d213326f35d68ffa8bf3abc6 /Modules | |
parent | 467f28de03bea1c27c33d6c0eb214b56cc837557 (diff) | |
download | cpython-65ec8ae47fa4bb0a3c2ef815ca1b03f3519398bc.zip cpython-65ec8ae47fa4bb0a3c2ef815ca1b03f3519398bc.tar.gz cpython-65ec8ae47fa4bb0a3c2ef815ca1b03f3519398bc.tar.bz2 |
Fix (hopefully) the remaining test_ssl buildbot failures
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/_ssl.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Modules/_ssl.c b/Modules/_ssl.c index 96d79b3..39fec7b 100644 --- a/Modules/_ssl.c +++ b/Modules/_ssl.c @@ -1462,6 +1462,10 @@ set_ciphers(PySSLContext *self, PyObject *args) return NULL; ret = SSL_CTX_set_cipher_list(self->ctx, cipherlist); if (ret == 0) { + /* Clearing the error queue is necessary on some OpenSSL versions, + otherwise the error will be reported again when another SSL call + is done. */ + ERR_clear_error(); PyErr_SetString(PySSLErrorObject, "No cipher can be selected."); return NULL; |