summary refs log tree commit diff
diff options
context:
space:
mode:
authorAlexander Barton <alex@barton.de>2008-11-11 22:01:27 +0100
committerAlexander Barton <alex@barton.de>2008-11-11 22:01:27 +0100
commit9308541e6df05d141ea51125877239e01ee5a1f5 (patch)
tree0f6daa5bbae51a1f977f9111209642c342f722b7
parent027cf22267e18cc8dec8f4e729267f9dec2060c3 (diff)
downloadngircd-9308541e6df05d141ea51125877239e01ee5a1f5.tar.gz
ngircd-9308541e6df05d141ea51125877239e01ee5a1f5.zip
Console log: output timestamp (seconds since start) for resolver, too
-rw-r--r--src/ngircd/log.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/ngircd/log.c b/src/ngircd/log.c
index fbe87f0e..5edbf368 100644
--- a/src/ngircd/log.c
+++ b/src/ngircd/log.c
@@ -334,11 +334,11 @@ va_dcl
 	vsnprintf( msg, MAX_LOG_MSG_LEN, Format, ap );
 	va_end( ap );
 
-	if( ! Is_Daemon )
-	{
+	if (!Is_Daemon) {
 		/* Output to console */
-		fprintf( stdout, "[%d:%d] %s\n", (int)getpid( ), Level, msg );
-		fflush( stdout );
+		fprintf(stdout, "[%d:%d %4ld] %s\n", (int)getpid( ), Level,
+			time(NULL) - NGIRCd_Start, msg);
+		fflush(stdout);
 	}
 #ifdef SYSLOG
 	else syslog( Level, "%s", msg );