diff options
author | dcs <dcs@FreeBSD.org> | 2001-08-03 17:36:06 +0000 |
---|---|---|
committer | dcs <dcs@FreeBSD.org> | 2001-08-03 17:36:06 +0000 |
commit | 908ed6c780646528fb0cd2b02ab2c4a8c9f9a27c (patch) | |
tree | 5292dc85b6a2efcd6504c0f6b8e8c0f285e994b7 | |
parent | 90376d10b0f4f691b5bd0c7028cbbc1dd3a758db (diff) | |
download | FreeBSD-src-908ed6c780646528fb0cd2b02ab2c4a8c9f9a27c.zip FreeBSD-src-908ed6c780646528fb0cd2b02ab2c4a8c9f9a27c.tar.gz |
MFS: Avoid dropping fragments in the absence of an interface address.
Noticed by: fenner
Submitted by: iedowse
Not committed to current by: iedowse ;-)
-rw-r--r-- | sys/netinet/ip_output.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/sys/netinet/ip_output.c b/sys/netinet/ip_output.c index 9c0f974..96e1e5f 100644 --- a/sys/netinet/ip_output.c +++ b/sys/netinet/ip_output.c @@ -961,10 +961,12 @@ sendorfree: /* clean ipsec history once it goes out of the node */ ipsec_delaux(m); #endif - if (error == 0 && ia) { + if (error == 0) { /* Record statistics for this interface address. */ - ia->ia_ifa.if_opackets++; - ia->ia_ifa.if_obytes += m->m_pkthdr.len; + if (ia != NULL) { + ia->ia_ifa.if_opackets++; + ia->ia_ifa.if_obytes += m->m_pkthdr.len; + } error = (*ifp->if_output)(ifp, m, (struct sockaddr *)dst, ro->ro_rt); |