From 722696b39e6a707b06e16d43edbd26197949a01e Mon Sep 17 00:00:00 2001 From: David Benjamin Date: Mon, 9 Feb 2015 19:59:14 -0500 Subject: [PATCH] Don't lock anything in SSL_set_generate_session_id. Nothing else on SSL* is thread-safe. (Also SSL_set_generate_session_id is never called.) This removes the last use of CRYPTO_LOCK_SSL. Change-Id: I4cf8c05d7cef4ea27962ce29902649317c22f74d Reviewed-on: https://boringssl-review.googlesource.com/3361 Reviewed-by: Adam Langley --- ssl/ssl_lib.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c index 34fff172..87f4d7bf 100644 --- a/ssl/ssl_lib.c +++ b/ssl/ssl_lib.c @@ -413,9 +413,7 @@ int SSL_CTX_set_generate_session_id(SSL_CTX *ctx, GEN_SESSION_CB cb) { } int SSL_set_generate_session_id(SSL *ssl, GEN_SESSION_CB cb) { - CRYPTO_w_lock(CRYPTO_LOCK_SSL); ssl->generate_session_id = cb; - CRYPTO_w_unlock(CRYPTO_LOCK_SSL); return 1; }