]> git.sur5r.net Git - openldap/commitdiff
ITS#3123 make sure ldap_int_sasl_mutex is init'd before it is used
authorHoward Chu <hyc@openldap.org>
Fri, 21 May 2004 10:53:30 +0000 (10:53 +0000)
committerHoward Chu <hyc@openldap.org>
Fri, 21 May 2004 10:53:30 +0000 (10:53 +0000)
libraries/libldap/cyrus.c
libraries/libldap/util-int.c

index 2b632482a8ad05f259dbcdfd3648862d55391fee..d98b534863e7272ab4cf2a457597e753db1ef9f9 100644 (file)
@@ -114,8 +114,6 @@ int ldap_int_sasl_init( void )
                ldap_pvt_sasl_mutex_lock,
                ldap_pvt_sasl_mutex_unlock,    
                ldap_pvt_sasl_mutex_dispose );    
-
-       ldap_pvt_thread_mutex_init( &ldap_int_sasl_mutex );
 #endif
 
        if ( sasl_client_init( NULL ) == SASL_OK ) {
index 2d3e3ba97be7d652574c540bf0ae7a7633fb63dd..e4975e0ff452aba2344eefdf2d165b39b5bcb3ee 100644 (file)
@@ -405,6 +405,10 @@ void ldap_int_utils_init( void )
        ldap_pvt_thread_mutex_init( &ldap_int_ctime_mutex );
 #endif
        ldap_pvt_thread_mutex_init( &ldap_int_resolv_mutex );
+
+#ifdef HAVE_CYRUS_SASL
+       ldap_pvt_thread_mutex_init( &ldap_int_sasl_mutex );
+#endif
 #endif
 
        /* call other module init functions here... */