Remove double fetch of "OSSL_EX_DATA_GLOBAL" for global lock
authorDavide Galassi <davxy@datawok.net>
Sun, 23 Feb 2020 09:01:45 +0000 (10:01 +0100)
committerTomas Mraz <tmraz@fedoraproject.org>
Mon, 9 Mar 2020 09:43:33 +0000 (10:43 +0100)
commit86cd42fbd3752dec442780867434e828f9a1a749
tree490c141bb763f36a42c33a555dd4bac50c63ea98
parent8293fb6840840a5252bb6671c48486bc86857b5f
Remove double fetch of "OSSL_EX_DATA_GLOBAL" for global lock

Fetch once and just pass the global ex_data to the "get_and_lock" static
function.

Removed a redundant null pointer check within the "get_and_lock" static
function (control already performed by the caller).

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Shane Lontis <shane.lontis@oracle.com>
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/11152)
crypto/ex_data.c