diff options
author | Florian Obser <florian@cvs.openbsd.org> | 2017-07-28 13:05:22 +0000 |
---|---|---|
committer | Florian Obser <florian@cvs.openbsd.org> | 2017-07-28 13:05:22 +0000 |
commit | 9c1b07f98d6a82f6555f1cb5c8240afab356fc88 (patch) | |
tree | 4e9e95678a7c904c2a7c9b9e2e923f03efa27db9 | |
parent | b2863214d4dd9010782195219909307a3a344c14 (diff) |
pass the size of the dst buffer to strlcat, not the source; pointed
out by clang
OK kettenis
-rw-r--r-- | usr.sbin/route6d/log.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/route6d/log.c b/usr.sbin/route6d/log.c index 3dd3aefe558..f943bfd9287 100644 --- a/usr.sbin/route6d/log.c +++ b/usr.sbin/route6d/log.c @@ -1,4 +1,4 @@ -/* $OpenBSD: log.c,v 1.3 2017/03/21 12:06:56 bluhm Exp $ */ +/* $OpenBSD: log.c,v 1.4 2017/07/28 13:05:21 florian Exp $ */ /* * Copyright (c) 2003, 2004 Henning Brauer <henning@openbsd.org> @@ -93,7 +93,7 @@ vlog(int pri, const char *fmt, va_list ap) (void)vsnprintf(tmpbuf, sizeof(tmpbuf), fmt, ap); (void)strlcpy(logbuf, logqueue, sizeof(logbuf)); - (void)strlcat(logbuf, tmpbuf, sizeof(tmpbuf)); + (void)strlcat(logbuf, tmpbuf, sizeof(logbuf)); logqueue[0] = '\0'; |