Use atomics for SSL_CTX statistics
authorBenjamin Kaduk <bkaduk@akamai.com>
Tue, 17 Oct 2017 19:46:58 +0000 (14:46 -0500)
committerBen Kaduk <kaduk@mit.edu>
Mon, 30 Oct 2017 15:18:09 +0000 (10:18 -0500)
commit1fcb4e4d521971caccb61df215541bf55f7ca9a5
tree5b753dc364d8444f6b8d59abfa9c27dbd01b85bd
parentce01b1896b57f3568c5af71e5b2912280171ba6e
Use atomics for SSL_CTX statistics

It is expected that SSL_CTX objects are shared across threads,
and as such we are responsible for ensuring coherent data accesses.
Aligned integer accesses ought to be atomic already on all supported
architectures, but we can be formally correct.

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/4549)
ssl/ssl_lib.c
ssl/ssl_sess.c
ssl/statem/statem_clnt.c
ssl/statem/statem_lib.c