Vrele ni_startdir in the experimental NFS server for the case

of NFSv2 getting an error return from VOP_MKNOD(). Without this
patch, the server file system remains busy after an NFSv2
VOP_MKNOD() fails.

MFC after:	2 weeks
This commit is contained in:
rmacklem 2011-04-11 20:54:30 +00:00
parent 61582b7c03
commit bf9a6130d2

View File

@ -765,10 +765,9 @@ nfsvno_createsub(struct nfsrv_descript *nd, struct nameidata *ndp,
&ndp->ni_cnd, &nvap->na_vattr);
vput(ndp->ni_dvp);
nfsvno_relpathbuf(ndp);
if (error) {
vrele(ndp->ni_startdir);
vrele(ndp->ni_startdir);
if (error)
return (error);
}
} else {
vrele(ndp->ni_startdir);
nfsvno_relpathbuf(ndp);