diff options
author | rwatson <rwatson@FreeBSD.org> | 2005-06-01 11:39:42 +0000 |
---|---|---|
committer | rwatson <rwatson@FreeBSD.org> | 2005-06-01 11:39:42 +0000 |
commit | ad803f0089d7983f5523c77147035e438b652a5a (patch) | |
tree | d4be4c7d592c18d440ea6e3c21a143a38ba494ab /sys/netinet | |
parent | 200ac8ea6b8615b75a54bc3aae5f82537b76ec21 (diff) | |
download | FreeBSD-src-ad803f0089d7983f5523c77147035e438b652a5a.zip FreeBSD-src-ad803f0089d7983f5523c77147035e438b652a5a.tar.gz |
Assert pcbinfo lock in in_pcbdisconnect() and in_pcbdetach(), as the
global pcb lists are modified.
MFC after: 7 days
Diffstat (limited to 'sys/netinet')
-rw-r--r-- | sys/netinet/in_pcb.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/netinet/in_pcb.c b/sys/netinet/in_pcb.c index 5e31c42..89f9d5b 100644 --- a/sys/netinet/in_pcb.c +++ b/sys/netinet/in_pcb.c @@ -692,6 +692,8 @@ void in_pcbdisconnect(inp) struct inpcb *inp; { + + INP_INFO_WLOCK_ASSERT(pcbinfo); INP_LOCK_ASSERT(inp); inp->inp_faddr.s_addr = INADDR_ANY; @@ -711,6 +713,7 @@ in_pcbdetach(inp) struct socket *so = inp->inp_socket; struct inpcbinfo *ipi = inp->inp_pcbinfo; + INP_INFO_WLOCK_ASSERT(pcbinfo); INP_LOCK_ASSERT(inp); #if defined(IPSEC) || defined(FAST_IPSEC) |