[openssl/openssl] 7e56ca: Make OPENSSL_cleanup() G A

0 views
Skip to first unread message

Bob Beck

unread,
Feb 5, 2026, 2:23:36 PM (2 days ago) Feb 5
to openssl...@openssl.org
Branch: refs/heads/master
Home: https://github.com/openssl/openssl
Commit: 7e56cab285e208c500110767c7edfaec9b96155c
https://github.com/openssl/openssl/commit/7e56cab285e208c500110767c7edfaec9b96155c
Author: Bob Beck <be...@openssl.org>
Date: 2026-02-05 (Thu, 05 Feb 2026)

Changed paths:
M CHANGES.md
M crypto/dllmain.c
M crypto/init.c
M doc/man3/OPENSSL_init_crypto.pod
M include/internal/e_os.h

Log Message:
-----------
Make OPENSSL_cleanup() G A

(Your choice of G and A words)

This installs a global destructor if we have destructor support.

The global destructor does nothing and immediately returns under
normal operation. If a global flag indicating that global cleanup
is wanted, it does what OPENSSL_cleanup() used to do.

OPENSSL_cleanup() is then modified to set the global flag indicating
that global cleanup is wanted. At this point if we have destructor
support, it immeditely returns. If we do not have destructor support,
it manually calls the destructor function (meaning without destructor
support it does exactly what it used to do).

This ensures that if we have destructor support, the actions of an
OPENSSL_cleanup() requested by an application will only happen
after any subordinate library destructors which could call into
OpenSSL functions have already run.

Reviewed-by: Neil Horman <nho...@openssl.org>
Reviewed-by: Saša Nedvědický <sas...@openssl.org>
MergeDate: Thu Feb 5 19:19:17 2026
(Merged from https://github.com/openssl/openssl/pull/29721)



To unsubscribe from these emails, change your notification settings at https://github.com/openssl/openssl/settings/notifications
Reply all
Reply to author
Forward
0 new messages