summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorDaniel Hartmeier <dhartmei@cvs.openbsd.org>2004-05-18 10:31:10 +0000
committerDaniel Hartmeier <dhartmei@cvs.openbsd.org>2004-05-18 10:31:10 +0000
commit6f276ce8e97c62d49b53f56fd8ccd3e6c0202c57 (patch)
tree3d28326c7a09234246a67a55280b9e9cf8720418 /sys
parent97eb5ebab45931d992c67275954fe89cec61d649 (diff)
fix size argument to ovbcopy() in ip_pcbopts(), found by Andrei Iltchenko
(FreeBSD PR 66386), ok markus@, otto@
Diffstat (limited to 'sys')
-rw-r--r--sys/netinet/ip_output.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c
index 0d220b0af8d..c156f1fc066 100644
--- a/sys/netinet/ip_output.c
+++ b/sys/netinet/ip_output.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip_output.c,v 1.161 2004/04/28 02:51:58 cedric Exp $ */
+/* $OpenBSD: ip_output.c,v 1.162 2004/05/18 10:31:09 dhartmei Exp $ */
/* $NetBSD: ip_output.c,v 1.28 1996/02/13 23:43:07 christos Exp $ */
/*
@@ -1581,7 +1581,7 @@ ip_pcbopts(pcbopt, m)
ovbcopy((caddr_t)(&cp[IPOPT_OFFSET+1] +
sizeof(struct in_addr)),
(caddr_t)&cp[IPOPT_OFFSET+1],
- (unsigned)cnt + sizeof(struct in_addr));
+ (unsigned)cnt - (IPOPT_OFFSET+1));
break;
}
}