diff options
author | 1997-07-09 00:16:12 +0000 | |
---|---|---|
committer | 1997-07-09 00:16:12 +0000 | |
commit | f2bea3d6500c57de9740502f725b751b60fd4c71 (patch) | |
tree | f62df5a0d2e18fb04d81c437a34e8c4631fe17a8 | |
parent | Improved a lot, not so much remains now, mostly the "operate format" stuff. (diff) | |
download | wireguard-openbsd-f2bea3d6500c57de9740502f725b751b60fd4c71.tar.xz wireguard-openbsd-f2bea3d6500c57de9740502f725b751b60fd4c71.zip |
Fix strncat(3) usage.
-rw-r--r-- | usr.sbin/lpr/lpr/lpr.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.sbin/lpr/lpr/lpr.c b/usr.sbin/lpr/lpr/lpr.c index b970087b5eb..e27aa660f6a 100644 --- a/usr.sbin/lpr/lpr/lpr.c +++ b/usr.sbin/lpr/lpr/lpr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: lpr.c,v 1.16 1997/07/08 18:25:42 millert Exp $ */ +/* $OpenBSD: lpr.c,v 1.17 1997/07/09 00:16:12 millert Exp $ */ /* $NetBSD: lpr.c,v 1.10 1996/03/21 18:12:25 jtc Exp $ */ /* @@ -50,7 +50,7 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)lpr.c 8.4 (Berkeley) 4/28/95"; #else -static char rcsid[] = "$OpenBSD: lpr.c,v 1.16 1997/07/08 18:25:42 millert Exp $"; +static char rcsid[] = "$OpenBSD: lpr.c,v 1.17 1997/07/09 00:16:12 millert Exp $"; #endif #endif /* not lint */ @@ -487,8 +487,8 @@ linked(file) } break; } - strncat(nfile, "/", sizeof(nfile) - strlen(nfile)); - strncat(nfile, file, sizeof(nfile) - strlen(nfile)); + strncat(nfile, "/", sizeof(nfile) - strlen(nfile) - 1); + strncat(nfile, file, sizeof(nfile) - strlen(nfile) - 1); file = nfile; } seteuid(euid); |