From d65bf0489435c3617966e3e1f084ffd736131185 Mon Sep 17 00:00:00 2001 From: Gary Williams Date: Wed, 25 Oct 2000 16:49:23 +0000 Subject: [PATCH] add logfile directive to config (behind NEW_LOGGING) --- servers/slapd/config.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/servers/slapd/config.c b/servers/slapd/config.c index 51fef27f45..7bf4e4f69b 100644 --- a/servers/slapd/config.c +++ b/servers/slapd/config.c @@ -814,6 +814,19 @@ read_config( const char *fname ) if ( level <= 0 ) level = lutil_mnem2level( cargv[2] ); lutil_set_debug_level( cargv[1], level ); /* specify an Object Identifier macro */ +#ifdef NEW_LOGGING + } else if ( strcasecmp( cargv[0], "logfile" ) == 0 ) { + FILE *logfile; + if ( cargc < 2 ) { + Debug( LDAP_DEBUG_ANY, + "%s: line %d: Error in logfile directive, \"logfile filename\"\n", + fname, lineno, 0 ); + return( 1 ); + } + logfile = fopen( cargv[1], "w" ); + if ( logfile != NULL ) lutil_debug_file( logfile ); + +#endif } else if ( strcasecmp( cargv[0], "objectidentifier" ) == 0 ) { parse_oidm( fname, lineno, cargc, cargv ); -- 2.39.5