[openssl/openssl] 540c2d: Don't call OPENSSL_init_crypto from inside a RUN_ONCE

Matt Caswell noreply at github.com
Tue Apr 4 07:38:39 UTC 2023


  Branch: refs/heads/master
  Home:   https://github.com/openssl/openssl
  Commit: 540c2d175d3c7c28bb969a74f6fe0396f0addc1a
      https://github.com/openssl/openssl/commit/540c2d175d3c7c28bb969a74f6fe0396f0addc1a
  Author: Matt Caswell <matt at openssl.org>
  Date:   2023-04-04 (Tue, 04 Apr 2023)

  Changed paths:
    M crypto/objects/obj_dat.c

  Log Message:
  -----------
  Don't call OPENSSL_init_crypto from inside a RUN_ONCE

Calling OPENSSL_init_crypto from inside a RUN_ONCE seems like a bad idea.
This is especially bad if OPENSSL_init_crypto can recursively end up
attempting to call the RUN_ONCE that we're already inside.

The initialisation in OPENSSL_init_crypto is already "run once" protected.
There is no need to protect it "twice".

Fixes #20653

Reviewed-by: Paul Dale <pauli at openssl.org>
Reviewed-by: Richard Levitte <levitte at openssl.org>
Reviewed-by: Tomas Mraz <tomas at openssl.org>
(Merged from https://github.com/openssl/openssl/pull/20662)

(cherry picked from commit a9745427cd5d44a76b31690b4a2c6bef2ee677c4)




More information about the openssl-commits mailing list