- (void) ldap_pvt_thread_initialize();
-
- ldap_pvt_thread_mutex_init( &active_threads_mutex );
- ldap_pvt_thread_cond_init( &active_threads_cond );
-
- ldap_pvt_thread_mutex_init( &new_conn_mutex );
- ldap_pvt_thread_mutex_init( ¤ttime_mutex );
- ldap_pvt_thread_mutex_init( &entry2str_mutex );
- ldap_pvt_thread_mutex_init( &replog_mutex );
- ldap_pvt_thread_mutex_init( &ops_mutex );
- ldap_pvt_thread_mutex_init( &num_sent_mutex );
-#ifdef SLAPD_CRYPT
- ldap_pvt_thread_mutex_init( &crypt_mutex );
+ (void) ldap_pvt_thread_initialize();
+
+ ldap_pvt_thread_pool_init(&connection_pool, connection_pool_max, 0);
+
+ ldap_pvt_thread_mutex_init( &entry2str_mutex );
+ ldap_pvt_thread_mutex_init( &replog_mutex );
+ ldap_pvt_thread_mutex_init( &num_ops_mutex );
+ ldap_pvt_thread_mutex_init( &num_sent_mutex );
+
+ ldap_pvt_thread_mutex_init( &gmtime_mutex );
+#if defined( SLAPD_CRYPT ) || defined( SLAPD_SPASSWD )
+ ldap_pvt_thread_mutex_init( &passwd_mutex );
+#endif
+
+ rc = slap_sasl_init();
+
+ if( rc == 0 ) {
+ rc = backend_init( );
+ }
+ break;
+
+ default:
+#ifdef NEW_LOGGING
+ LDAP_LOG(( "operation", LDAP_LEVEL_ERR,
+ "init: %s init, undefined mode (%d).\n", name, mode ));
+#else
+ Debug( LDAP_DEBUG_ANY,
+ "%s init: undefined mode (%d).\n", name, mode, 0 );