diff options
author | Damien Miller <djm@cvs.openbsd.org> | 2004-05-25 23:51:31 +0000 |
---|---|---|
committer | Damien Miller <djm@cvs.openbsd.org> | 2004-05-25 23:51:31 +0000 |
commit | 8f98ad10403c1cce3d6bf637c531b95ef5939054 (patch) | |
tree | ea506cf1525c57279318943687a264edd3b12ed0 /usr.sbin | |
parent | 1e98360386ed0c7344709035d1e420b85f67525b (diff) |
include hostname in memory buffered logs, spotted by
ssurdock AT engineered-net.com; ok deraadt@
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/syslogd/syslogd.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/usr.sbin/syslogd/syslogd.c b/usr.sbin/syslogd/syslogd.c index 4ad071e3535..07d589c02ab 100644 --- a/usr.sbin/syslogd/syslogd.c +++ b/usr.sbin/syslogd/syslogd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: syslogd.c,v 1.76 2004/04/15 18:13:07 millert Exp $ */ +/* $OpenBSD: syslogd.c,v 1.77 2004/05/25 23:51:30 djm Exp $ */ /* * Copyright (c) 1983, 1988, 1993, 1994 @@ -39,7 +39,7 @@ static const char copyright[] = #if 0 static const char sccsid[] = "@(#)syslogd.c 8.3 (Berkeley) 4/4/94"; #else -static const char rcsid[] = "$OpenBSD: syslogd.c,v 1.76 2004/04/15 18:13:07 millert Exp $"; +static const char rcsid[] = "$OpenBSD: syslogd.c,v 1.77 2004/05/25 23:51:30 djm Exp $"; #endif #endif /* not lint */ @@ -890,8 +890,9 @@ fprintlog(struct filed *f, int flags, char *msg) case F_MEMBUF: dprintf("\n"); - snprintf(line, sizeof(line), "%.15s %s", - (char *)iov[0].iov_base, (char *)iov[4].iov_base); + snprintf(line, sizeof(line), "%.15s %s %s", + (char *)iov[0].iov_base, (char *)iov[2].iov_base, + (char *)iov[4].iov_base); ringbuf_append_line(f->f_un.f_mb.f_rb, line); break; } |