diff options
author | Andrew Tridgell <tridge@samba.org> | 1998-10-30 02:43:10 +0000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 1998-10-30 02:43:10 +0000 |
commit | b24203b323c86e250054bff19274b1f466303712 (patch) | |
tree | 411964e457578b9a95699fa3eaa542ae9fc52616 /log.c | |
parent | 347200978968f7224b13287c5e3a25cf2041af53 (diff) | |
download | rsync-b24203b323c86e250054bff19274b1f466303712.tar.gz rsync-b24203b323c86e250054bff19274b1f466303712.tar.bz2 rsync-b24203b323c86e250054bff19274b1f466303712.zip |
get null termination right in logging
Diffstat (limited to 'log.c')
-rw-r--r-- | log.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -106,9 +106,6 @@ void log_open(void) FILE *f=NULL; extern int am_daemon; /* recursion can happen with certain fatal conditions */ - static int depth; - - if (depth) return; va_start(ap, format); len = vslprintf(buf, sizeof(buf)-1, format, ap); @@ -126,9 +123,12 @@ void log_open(void) } if (am_daemon) { + static int depth; int priority = LOG_INFO; if (fd == FERROR) priority = LOG_WARNING; + if (depth) return; + depth++; log_open(); |