summaryrefslogtreecommitdiffstats
path: root/sys/netinet/udp_usrreq.c
diff options
context:
space:
mode:
authorbmilekic <bmilekic@FreeBSD.org>2001-02-11 07:39:51 +0000
committerbmilekic <bmilekic@FreeBSD.org>2001-02-11 07:39:51 +0000
commit0f9088da5625e8088bdbd7b3587fdadb265b1482 (patch)
tree05dfca28095c82a06dee66b4ae5d1541036a93af /sys/netinet/udp_usrreq.c
parentcc52eb42bff57e11d166025d0d19cae8152a462d (diff)
downloadFreeBSD-src-0f9088da5625e8088bdbd7b3587fdadb265b1482.zip
FreeBSD-src-0f9088da5625e8088bdbd7b3587fdadb265b1482.tar.gz
Clean up RST ratelimiting. Previously, ratelimiting occured before tests
were performed to determine if the received packet should be reset. This created erroneous ratelimiting and false alarms in some cases. The code has now been reorganized so that the checks for validity come before the call to badport_bandlim. Additionally, a few changes in the symbolic names of the bandlim types have been made, as well as a clarification of exactly which type each RST case falls under. Submitted by: Mike Silbersack <silby@silby.com>
Diffstat (limited to 'sys/netinet/udp_usrreq.c')
-rw-r--r--sys/netinet/udp_usrreq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c
index 5c92f62..468064f 100644
--- a/sys/netinet/udp_usrreq.c
+++ b/sys/netinet/udp_usrreq.c
@@ -353,7 +353,7 @@ udp_input(m, off, proto)
udpstat.udps_noportbcast++;
goto bad;
}
- if (badport_bandlim(BANDLIM_UNREACH) < 0)
+ if (badport_bandlim(BANDLIM_ICMP_UNREACH) < 0)
goto bad;
if (blackhole)
goto bad;
OpenPOWER on IntegriCloud