summaryrefslogtreecommitdiff
path: root/usr.bin/lam
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2003-04-06 02:40:22 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2003-04-06 02:40:22 +0000
commit3d0f8ae22e810aef00073168f02cfe53c32996e8 (patch)
treed5067a4dfedf41c17fa43d646c6b0d85eea9930a /usr.bin/lam
parent98bc7e31e95ca44bd4d9ac4c969e1aae743ee307 (diff)
Consider 0 characters left to be a lack of format space.
ok deraadt@ millert@
Diffstat (limited to 'usr.bin/lam')
-rw-r--r--usr.bin/lam/lam.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/lam/lam.c b/usr.bin/lam/lam.c
index 732db18e274..a3a7f96b537 100644
--- a/usr.bin/lam/lam.c
+++ b/usr.bin/lam/lam.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: lam.c,v 1.5 2003/04/05 16:24:23 deraadt Exp $ */
+/* $OpenBSD: lam.c,v 1.6 2003/04/06 02:40:21 krw Exp $ */
/* $NetBSD: lam.c,v 1.2 1994/11/14 20:27:42 jtc Exp $ */
/*-
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)lam.c 8.1 (Berkeley) 6/6/93";
#endif
-static char rcsid[] = "$OpenBSD: lam.c,v 1.5 2003/04/05 16:24:23 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: lam.c,v 1.6 2003/04/06 02:40:21 krw Exp $";
#endif /* not lint */
/*
@@ -155,7 +155,7 @@ getargs(av)
F = (*c == 'F' ? 1 : 0);
if (*++p || (p = *++av)) {
fmtp += strlen(fmtp) + 1;
- if (fmtp > fmtbuf + BUFSIZ)
+ if (fmtp >= fmtbuf + BUFSIZ)
error("No more format space", "");
snprintf(fmtp, fmtbuf + BUFSIZ - fmtp,
"%%%ss", p);