mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-20 22:59:34 -05:00
Revert "ITS#9952 libldap: use atexit for TLS teardown"
This reverts commit 337455eb3a.
The change was non-portable, caused ITS#10176. OpenSSL 3 is
broken and should be fixed.
This commit is contained in:
parent
af7575fabd
commit
5e13ef87a9
2 changed files with 4 additions and 13 deletions
|
|
@ -544,6 +544,9 @@ ldap_int_destroy_global_options(void)
|
||||||
gopts->ldo_def_sasl_authcid = NULL;
|
gopts->ldo_def_sasl_authcid = NULL;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef HAVE_TLS
|
||||||
|
ldap_int_tls_destroy( gopts );
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
||||||
|
|
@ -160,14 +160,6 @@ ldap_pvt_tls_destroy( void )
|
||||||
tls_imp->ti_tls_destroy();
|
tls_imp->ti_tls_destroy();
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
ldap_exit_tls_destroy( void )
|
|
||||||
{
|
|
||||||
struct ldapoptions *lo = LDAP_INT_GLOBAL_OPT();
|
|
||||||
|
|
||||||
ldap_int_tls_destroy( lo );
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Initialize a particular TLS implementation.
|
* Initialize a particular TLS implementation.
|
||||||
* Called once per implementation.
|
* Called once per implementation.
|
||||||
|
|
@ -176,7 +168,6 @@ static int
|
||||||
tls_init(tls_impl *impl, int do_threads )
|
tls_init(tls_impl *impl, int do_threads )
|
||||||
{
|
{
|
||||||
static int tls_initialized = 0;
|
static int tls_initialized = 0;
|
||||||
int rc;
|
|
||||||
|
|
||||||
if ( !tls_initialized++ ) {
|
if ( !tls_initialized++ ) {
|
||||||
#ifdef LDAP_R_COMPILE
|
#ifdef LDAP_R_COMPILE
|
||||||
|
|
@ -192,10 +183,7 @@ tls_init(tls_impl *impl, int do_threads )
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
rc = impl->ti_tls_init();
|
return impl->ti_tls_init();
|
||||||
|
|
||||||
atexit( ldap_exit_tls_destroy );
|
|
||||||
return rc;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue