aboutsummaryrefslogtreecommitdiff
path: root/sys/netinet/udp_usrreq.c
diff options
context:
space:
mode:
authorAndre Oppermann <andre@FreeBSD.org>2005-08-22 16:13:08 +0000
committerAndre Oppermann <andre@FreeBSD.org>2005-08-22 16:13:08 +0000
commit936cd18dade566c7ca5fd50cb4658f71f87ffcc1 (patch)
treee4fae08b9c2716f53ec0fdfe0bc72046c99f26b9 /sys/netinet/udp_usrreq.c
parent6b773dff30ea223c1ece875d88921ddc8876806e (diff)
Notes
Diffstat (limited to 'sys/netinet/udp_usrreq.c')
-rw-r--r--sys/netinet/udp_usrreq.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/netinet/udp_usrreq.c b/sys/netinet/udp_usrreq.c
index 0ffb00445ce80..6de2d7b774747 100644
--- a/sys/netinet/udp_usrreq.c
+++ b/sys/netinet/udp_usrreq.c
@@ -384,6 +384,9 @@ udp_input(m, off)
return;
}
INP_LOCK(inp);
+ /* Check the minimum TTL for socket. */
+ if (inp->inp_ip_minttl && inp->inp_ip_minttl > ip->ip_ttl)
+ goto badheadlocked;
udp_append(inp, ip, m, iphlen + sizeof(struct udphdr), &udp_in);
INP_UNLOCK(inp);
INP_INFO_RUNLOCK(&udbinfo);