summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2001-03-03 01:09:29 +0000
committerJun-ichiro itojun Hagino <itojun@cvs.openbsd.org>2001-03-03 01:09:29 +0000
commit88ad3c767812c08478204972155123abed4eca02 (patch)
treefc7f12280b4be5796c214865225fb4ded3182f42
parent8871a2d76744799efa054ac8b5c6ba4edecde215 (diff)
on parse error of timestamp option, set parameter error offset correctly.
-rw-r--r--sys/netinet/ip_input.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/netinet/ip_input.c b/sys/netinet/ip_input.c
index ad21ded43b5..d9ab71c599c 100644
--- a/sys/netinet/ip_input.c
+++ b/sys/netinet/ip_input.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip_input.c,v 1.62 2001/03/03 01:00:19 itojun Exp $ */
+/* $OpenBSD: ip_input.c,v 1.63 2001/03/03 01:09:28 itojun Exp $ */
/* $NetBSD: ip_input.c,v 1.30 1996/03/16 23:53:58 christos Exp $ */
/*
@@ -1221,6 +1221,9 @@ ip_dooptions(m)
break;
default:
+ /* XXX can't take &ipt->ipt_flg */
+ code = (u_char *)&ipt.ipt_ptr -
+ (u_char *)ip + 1;
goto bad;
}
ntime = iptime();