diff options
author | darrenr <darrenr@FreeBSD.org> | 2001-02-04 14:25:38 +0000 |
---|---|---|
committer | darrenr <darrenr@FreeBSD.org> | 2001-02-04 14:25:38 +0000 |
commit | 5e62aa9b3dacb0e670998fad60638b79751aff14 (patch) | |
tree | 385e237f9b94bd1f0ddf97318d3ced6f6e85ec8b /contrib/ipfilter/ip_frag.c | |
parent | 77a62e2a58642d4f2e31e9cfc354994062d9777b (diff) | |
download | FreeBSD-src-5e62aa9b3dacb0e670998fad60638b79751aff14.zip FreeBSD-src-5e62aa9b3dacb0e670998fad60638b79751aff14.tar.gz |
Import IP Filter update
Diffstat (limited to 'contrib/ipfilter/ip_frag.c')
-rw-r--r-- | contrib/ipfilter/ip_frag.c | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/contrib/ipfilter/ip_frag.c b/contrib/ipfilter/ip_frag.c index 1cb86c1..556478d 100644 --- a/contrib/ipfilter/ip_frag.c +++ b/contrib/ipfilter/ip_frag.c @@ -7,7 +7,7 @@ */ #if !defined(lint) static const char sccsid[] = "@(#)ip_frag.c 1.11 3/24/96 (C) 1993-2000 Darren Reed"; -static const char rcsid[] = "@(#)$Id: ip_frag.c,v 2.10.2.5 2000/10/19 15:39:58 darrenr Exp $"; +static const char rcsid[] = "@(#)$Id: ip_frag.c,v 2.10.2.7 2000/11/27 10:26:56 darrenr Exp $"; #endif #if defined(KERNEL) && !defined(_KERNEL) @@ -156,6 +156,7 @@ ipfr_t *table[]; idx += ip->ip_src.s_addr; frag.ipfr_dst.s_addr = ip->ip_dst.s_addr; idx += ip->ip_dst.s_addr; + frag.ipfr_ifp = fin->fin_ifp; idx *= 127; idx %= IPFT_SIZE; @@ -270,6 +271,7 @@ ipfr_t *table[]; idx += ip->ip_src.s_addr; frag.ipfr_dst.s_addr = ip->ip_dst.s_addr; idx += ip->ip_dst.s_addr; + frag.ipfr_ifp = fin->fin_ifp; idx *= 127; idx %= IPFT_SIZE; @@ -328,16 +330,13 @@ fr_info_t *fin; ipf = ipfr_lookup(ip, fin, ipfr_nattab); if (ipf != NULL) { nat = ipf->ipfr_data; - if (nat->nat_ifp == fin->fin_ifp) { - /* - * This is the last fragment for this packet. - */ - if ((ipf->ipfr_ttl == 1) && (nat != NULL)) { - nat->nat_data = NULL; - ipf->ipfr_data = NULL; - } - } else - nat = NULL; + /* + * This is the last fragment for this packet. + */ + if ((ipf->ipfr_ttl == 1) && (nat != NULL)) { + nat->nat_data = NULL; + ipf->ipfr_data = NULL; + } } else nat = NULL; RWLOCK_EXIT(&ipf_natfrag); |