diff options
author | dwmalone <dwmalone@FreeBSD.org> | 2001-10-29 20:04:03 +0000 |
---|---|---|
committer | dwmalone <dwmalone@FreeBSD.org> | 2001-10-29 20:04:03 +0000 |
commit | 162339bdefcadb6b4f8da4e2fecb1267dc552155 (patch) | |
tree | 89b313f97cee557c3810ca4d650cbed4f0c66945 /sys/kern/uipc_usrreq.c | |
parent | 1c9daba05c5123d12a5254859695d5b854900542 (diff) | |
download | FreeBSD-src-162339bdefcadb6b4f8da4e2fecb1267dc552155.zip FreeBSD-src-162339bdefcadb6b4f8da4e2fecb1267dc552155.tar.gz |
When scanning for control messages, don't process the data mbufs.
This could cause hangs if a unix domain socket was closed with data
still to be read from it.
Tested by: Andrea Campi <andrea@webcom.it>
Diffstat (limited to 'sys/kern/uipc_usrreq.c')
-rw-r--r-- | sys/kern/uipc_usrreq.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/kern/uipc_usrreq.c b/sys/kern/uipc_usrreq.c index 12af404..c8dc5fc 100644 --- a/sys/kern/uipc_usrreq.c +++ b/sys/kern/uipc_usrreq.c @@ -1420,7 +1420,7 @@ unp_scan(m0, op) while (m0) { for (m = m0; m; m = m->m_next) { - if (m->m_type == MT_CONTROL) + if (m->m_type != MT_CONTROL) continue; cm = mtod(m, struct cmsghdr *); |