diff options
| author | dane dane@31f1291d-b8d6-0310-a050-a5561fc1590b <dane dane@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864> | 2004-08-26 14:26:06 +0000 |
|---|---|---|
| committer | dane dane@31f1291d-b8d6-0310-a050-a5561fc1590b <dane dane@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864> | 2004-08-26 14:26:06 +0000 |
| commit | 5c3ee8a19acbdc26f191386776207fb7fefb4930 (patch) | |
| tree | 6c577835b47bcd7a5f7db1f9d7f1fe33b319770d /src/log.c | |
| parent | b05797bb10efec25579bda27ff4338f0b7803ac2 (diff) | |
BUILD : 1.7.5 (335) BUGS : 142, 152, 154, 155, 156, 157, 158 NOTES : Applied bugfix bundle patch from Trystan.
git-svn-id: svn://svn.anope.org/anope/trunk@335 31f1291d-b8d6-0310-a050-a5561fc1590b
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@211 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/log.c')
| -rw-r--r-- | src/log.c | 13 |
1 files changed, 13 insertions, 0 deletions
@@ -125,6 +125,10 @@ void alog(const char *fmt, ...) checkday(); + if (!fmt) { + return; + } + va_start(args, fmt); time(&t); tm = *localtime(&t); @@ -160,6 +164,7 @@ void alog(const char *fmt, ...) privmsg(s_GlobalNoticer, LogChannel, str); } + va_end(args); errno = errno_save; } @@ -178,6 +183,10 @@ void log_perror(const char *fmt, ...) checkday(); + if (!fmt) { + return; + } + va_start(args, fmt); time(&t); tm = *localtime(&t); @@ -207,6 +216,7 @@ void log_perror(const char *fmt, ...) fprintf(stderr, ": %s\n", strerror(errno_save)); } errno = errno_save; + va_end(args); } /*************************************************************************/ @@ -249,6 +259,8 @@ void fatal(const char *fmt, ...) fprintf(stderr, "%sFATAL: %s\n", buf, buf2); if (servsock >= 0) anope_cmd_global(NULL, "FATAL ERROR! %s", buf2); + + va_end(args); exit(1); } @@ -293,6 +305,7 @@ void fatal_perror(const char *fmt, ...) if (servsock >= 0) anope_cmd_global(NULL, "FATAL ERROR! %s: %s", buf2, strerror(errno_save)); + va_end(args); exit(1); } |
