diff options
author | Chad Loder <cloder@cvs.openbsd.org> | 2003-09-28 23:17:46 +0000 |
---|---|---|
committer | Chad Loder <cloder@cvs.openbsd.org> | 2003-09-28 23:17:46 +0000 |
commit | 962b98cc3919ea12ffd86bc697aa4e3f505812e1 (patch) | |
tree | 05958672c1af6f91bf539cf823eab1b45c2c6b41 /sys/netinet6/in6_pcb.c | |
parent | ac8974a8de51edc4a7838f60167f279ffe4da0b9 (diff) |
Correct off-by-ones with respect to PRC_NCMDS. Mostly from FreeBSD.
OK krw@, deraadt@
Diffstat (limited to 'sys/netinet6/in6_pcb.c')
-rw-r--r-- | sys/netinet6/in6_pcb.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netinet6/in6_pcb.c b/sys/netinet6/in6_pcb.c index fe423a75fb9..ab7d7376f43 100644 --- a/sys/netinet6/in6_pcb.c +++ b/sys/netinet6/in6_pcb.c @@ -1,4 +1,4 @@ -/* $OpenBSD: in6_pcb.c,v 1.35 2003/08/15 20:32:20 tedu Exp $ */ +/* $OpenBSD: in6_pcb.c,v 1.36 2003/09/28 23:17:45 cloder Exp $ */ /* * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. @@ -561,7 +561,7 @@ in6_pcbnotify(head, dst, fport_arg, src, lport_arg, cmd, cmdarg, notify) int errno, nmatch = 0; u_int32_t flowinfo; - if ((unsigned)cmd > PRC_NCMDS || dst->sa_family != AF_INET6) + if ((unsigned)cmd >= PRC_NCMDS || dst->sa_family != AF_INET6) return 1; sa6_dst = (struct sockaddr_in6 *)dst; |