diff options
author | rmacklem <rmacklem@FreeBSD.org> | 2011-04-11 20:54:30 +0000 |
---|---|---|
committer | rmacklem <rmacklem@FreeBSD.org> | 2011-04-11 20:54:30 +0000 |
commit | bf9a6130d2c4bc18f7fa41d67bbf100684430dc2 (patch) | |
tree | bf376f7a364bffcf30e42768003ada74850ebaf9 /sys/fs | |
parent | 61582b7c03cbf76a3a9b58e08d2625709738fabc (diff) | |
download | FreeBSD-src-bf9a6130d2c4bc18f7fa41d67bbf100684430dc2.zip FreeBSD-src-bf9a6130d2c4bc18f7fa41d67bbf100684430dc2.tar.gz |
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
Diffstat (limited to 'sys/fs')
-rw-r--r-- | sys/fs/nfsserver/nfs_nfsdport.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/fs/nfsserver/nfs_nfsdport.c b/sys/fs/nfsserver/nfs_nfsdport.c index 8f5f3cd..c97df89 100644 --- a/sys/fs/nfsserver/nfs_nfsdport.c +++ b/sys/fs/nfsserver/nfs_nfsdport.c @@ -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); |