diff options
Diffstat (limited to 'accel-pptpd/log.c')
-rw-r--r-- | accel-pptpd/log.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/accel-pptpd/log.c b/accel-pptpd/log.c index 4ee86e1a..992f24d5 100644 --- a/accel-pptpd/log.c +++ b/accel-pptpd/log.c @@ -33,7 +33,7 @@ #define LOG_INFO 2 #define LOG_DEBUG 3 -static FILE *log_file=NULL; +static FILE *log_file; static int log_level=10; static int log_color=1; static const char* level_name[]={"error","warning","info","debug"}; @@ -47,6 +47,8 @@ static void do_log(int level,const char *fmt,va_list ap) struct timeval tv; //pthread_mutex_lock(&lock); + if (!log_file) + log_file=stdout; if (msg_completed) { gettimeofday(&tv,NULL); |