From: Kurt Zeilenga Date: Mon, 17 Sep 2001 22:38:52 +0000 (+0000) Subject: Clean up include logging X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~1097 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=d05e6af326c9983f135c2f7a6b874457a9d5adbf;p=openldap Clean up include logging --- diff --git a/servers/slapd/config.c b/servers/slapd/config.c index f20979649e..8301956036 100644 --- a/servers/slapd/config.c +++ b/servers/slapd/config.c @@ -12,6 +12,7 @@ #include #include #include +#include #include "lutil.h" #include "ldap_pvt.h" @@ -85,16 +86,21 @@ read_config( const char *fname ) if ( (fp = fopen( fname, "r" )) == NULL ) { ldap_syslog = 1; +#ifdef NEW_LOGGING + LDAP_LOG(( "config", LDAP_LEVEL_ENTRY, "read_config: " + "could not open config file \"%s\": %s (%d)\n", + fname, strerror(errno), errno )); +#else Debug( LDAP_DEBUG_ANY, - "could not open config file \"%s\" - absolute path?\n", - fname, 0, 0 ); - perror( fname ); + "could not open config file \"%s\": %s (%d)\n", + fname, strerror(errno), errno ); +#endif return 1; } #ifdef NEW_LOGGING LDAP_LOG(( "config", LDAP_LEVEL_ENTRY, - "read_config: reading config file %s\n", fname )); + "read_config: reading config file %s\n", fname )); #else Debug( LDAP_DEBUG_CONFIG, "reading config file %s\n", fname, 0, 0 ); #endif