summaryrefslogtreecommitdiff
path: root/sys/net
diff options
context:
space:
mode:
authorDaniel Hartmeier <dhartmei@cvs.openbsd.org>2002-03-30 06:21:01 +0000
committerDaniel Hartmeier <dhartmei@cvs.openbsd.org>2002-03-30 06:21:01 +0000
commit836faf5416a873bddbe1fbace4ad7bab6eb7726f (patch)
tree1e0d9b171c2b125b6a46c64a146b19c3c4d587e8 /sys/net
parent9850eb7c03833609353da9710cdd9913f562d866 (diff)
Initialize sequence number high limit from 1 to the real value with the
first packet. ok frantzen@
Diffstat (limited to 'sys/net')
-rw-r--r--sys/net/pf.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/net/pf.c b/sys/net/pf.c
index 956d70a903b..66a74b03005 100644
--- a/sys/net/pf.c
+++ b/sys/net/pf.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pf.c,v 1.198 2002/03/27 18:16:21 mickey Exp $ */
+/* $OpenBSD: pf.c,v 1.199 2002/03/30 06:21:00 dhartmei Exp $ */
/*
* Copyright (c) 2001 Daniel Hartmeier
@@ -3859,7 +3859,8 @@ pf_test_state_tcp(struct pf_state **state, int direction, struct ifnet *ifp,
* the crappy stack check or if we picked up the connection
* after establishment)
*/
- if (SEQ_GEQ(end + MAX(1, dst->max_win), src->seqhi))
+ if (src->seqhi == 1 ||
+ SEQ_GEQ(end + MAX(1, dst->max_win), src->seqhi))
src->seqhi = end + MAX(1, dst->max_win);
if (win > src->max_win)
src->max_win = win;