diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2007-02-23 15:26:53 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2007-02-23 15:26:53 +0000 |
commit | cb4266629ffef9fdae7bd2170bd88661b6e5a36d (patch) | |
tree | be433cf334d82524d83b336e8c497c3c26e55bbd /usr.bin | |
parent | 680af668cce2ecb6fed103a0af33ff66c4b24ce9 (diff) |
add back in character count check by Tamas TEVESZ, though this does
not truly handle trailing whitespace on the line. but that is handled
very weakly for other patterns, too.
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/vacation/vacation.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/usr.bin/vacation/vacation.c b/usr.bin/vacation/vacation.c index 18ba36d3c86..3a79857e2e7 100644 --- a/usr.bin/vacation/vacation.c +++ b/usr.bin/vacation/vacation.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vacation.c,v 1.25 2007/02/23 15:18:59 deraadt Exp $ */ +/* $OpenBSD: vacation.c,v 1.26 2007/02/23 15:26:52 deraadt Exp $ */ /* $NetBSD: vacation.c,v 1.7 1995/04/29 05:58:27 cgd Exp $ */ /* @@ -40,7 +40,7 @@ static char copyright[] = #if 0 static char sccsid[] = "@(#)vacation.c 8.2 (Berkeley) 1/26/94"; #endif -static char rcsid[] = "$OpenBSD: vacation.c,v 1.25 2007/02/23 15:18:59 deraadt Exp $"; +static char rcsid[] = "$OpenBSD: vacation.c,v 1.26 2007/02/23 15:26:52 deraadt Exp $"; #endif /* not lint */ /* @@ -221,7 +221,7 @@ readheaders(void) */ if (!*p) exit(0); - if (strncasecmp(p, "no", 2)) + if (strlen(p) != 3 || strncasecmp(p, "no", 2)) exit(0); break; case 'F': /* "From " */ |