From: Kurt Zeilenga Date: Thu, 2 Aug 2001 03:37:20 +0000 (+0000) Subject: Add some addl. logging X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~1171 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=b22ad8cf601619f965354256857590b841467fec;p=openldap Add some addl. logging --- diff --git a/servers/slapd/main.c b/servers/slapd/main.c index ebf130a0be..8801d79c59 100644 --- a/servers/slapd/main.c +++ b/servers/slapd/main.c @@ -399,8 +399,30 @@ int main( int argc, char **argv ) #ifdef HAVE_TLS rc = ldap_pvt_tls_init(); + if( rc != 0) { +#ifdef NEW_LOGGING + LDAP_LOG(( "operation", LDAP_LEVEL_CRIT, + "main: tls init failed: %d\n", rc )); +#else + Debug( LDAP_DEBUG_ANY, + "main: TLS init failed: %d\n", + 0, 0, 0 ); +#endif + rc = 1; + SERVICE_EXIT( ERROR_SERVICE_SPECIFIC_ERROR, 20 ); + goto destroy; + } - if (rc || ldap_pvt_tls_init_def_ctx() != 0) { + rc = ldap_pvt_tls_init_def_ctx(); + if( rc != 0) { +#ifdef NEW_LOGGING + LDAP_LOG(( "operation", LDAP_LEVEL_CRIT, + "main: tls init def ctx failed: %d\n", rc )); +#else + Debug( LDAP_DEBUG_ANY, + "main: TLS init def ctx failed: %d\n", + 0, 0, 0 ); +#endif rc = 1; SERVICE_EXIT( ERROR_SERVICE_SPECIFIC_ERROR, 20 ); goto destroy;