From 1b79f745fe2ef23c42edd29217dc441025a55bd8 Mon Sep 17 00:00:00 2001 From: Gary Williams Date: Thu, 1 Apr 1999 16:39:36 +0000 Subject: [PATCH] enable debug output for NT --- servers/slapd/nt_debug.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 servers/slapd/nt_debug.c diff --git a/servers/slapd/nt_debug.c b/servers/slapd/nt_debug.c new file mode 100644 index 0000000000..e506531b82 --- /dev/null +++ b/servers/slapd/nt_debug.c @@ -0,0 +1,19 @@ +#include +#include + +static FILE *log_file; + +void Debug( int level, char *fmt, ... ) +{ + char buffer[4096]; + va_list vl; + + if( log_file == NULL ) + log_file = fopen( "C:\\OpenLDAP\\run\\slapd.log", "w" ); + + va_start( vl, fmt ); + vsprintf( buffer, fmt, vl ); + fprintf( log_file, "%s\n", buffer ); + fflush( log_file ); + va_end( vl ); +} -- 2.39.5