Changeset View
Changeset View
Standalone View
Standalone View
sys/kern/uipc_usrreq.c
Show First 20 Lines • Show All 2,763 Lines • ▼ Show 20 Lines | |||||
/* | /* | ||||
* Synchronize against unp_gc, which can trip over data as we are freeing it. | * Synchronize against unp_gc, which can trip over data as we are freeing it. | ||||
*/ | */ | ||||
static void | static void | ||||
unp_dispose(struct socket *so) | unp_dispose(struct socket *so) | ||||
{ | { | ||||
struct unpcb *unp; | struct unpcb *unp; | ||||
MPASS(!SOLISTENING(so)); | |||||
unp = sotounpcb(so); | unp = sotounpcb(so); | ||||
UNP_LINK_WLOCK(); | UNP_LINK_WLOCK(); | ||||
unp->unp_gcflag |= UNPGC_IGNORE_RIGHTS; | unp->unp_gcflag |= UNPGC_IGNORE_RIGHTS; | ||||
UNP_LINK_WUNLOCK(); | UNP_LINK_WUNLOCK(); | ||||
if (!SOLISTENING(so)) | |||||
unp_dispose_mbuf(so->so_rcv.sb_mb); | unp_dispose_mbuf(so->so_rcv.sb_mb); | ||||
} | } | ||||
static void | static void | ||||
unp_scan(struct mbuf *m0, void (*op)(struct filedescent **, int)) | unp_scan(struct mbuf *m0, void (*op)(struct filedescent **, int)) | ||||
{ | { | ||||
struct mbuf *m; | struct mbuf *m; | ||||
struct cmsghdr *cm; | struct cmsghdr *cm; | ||||
void *data; | void *data; | ||||
▲ Show 20 Lines • Show All 187 Lines • Show Last 20 Lines |