When aborting a UNIX domain socket bind() because VOP_CREATE() failed,

make sure to call vn_finished_write(mp) before returning.

MFC after:	3 days
This commit is contained in:
Robert Watson 2005-02-21 14:21:50 +00:00
parent 1d2a8153d3
commit c364c823d0

View File

@ -833,8 +833,10 @@ unp_bind(struct unpcb *unp, struct sockaddr *nam, struct thread *td)
}
NDFREE(&nd, NDF_ONLY_PNBUF);
vput(nd.ni_dvp);
if (error)
if (error) {
vn_finished_write(mp);
goto done;
}
vp = nd.ni_vp;
ASSERT_VOP_LOCKED(vp, "unp_bind");
soun = (struct sockaddr_un *)sodupsockaddr(nam, M_WAITOK);