Date: Mon, 2 May 2011 00:49:47 +0000 (UTC) From: Rick Macklem <rmacklem@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r221310 - stable/8/sys/fs/nfsclient Message-ID: <201105020049.p420nlfD014704@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rmacklem Date: Mon May 2 00:49:47 2011 New Revision: 221310 URL: http://svn.freebsd.org/changeset/base/221310 Log: MFC: r220763 Add vput() calls in two places in the experimental NFS client that would be needed if, in the future, nfscl_loadattrcache() were to return an error. Currently nfscl_loadattrcache() never returns an error, so these cases never currently happen. Modified: stable/8/sys/fs/nfsclient/nfs_clvnops.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) Modified: stable/8/sys/fs/nfsclient/nfs_clvnops.c ============================================================================== --- stable/8/sys/fs/nfsclient/nfs_clvnops.c Sun May 1 23:55:56 2011 (r221309) +++ stable/8/sys/fs/nfsclient/nfs_clvnops.c Mon May 2 00:49:47 2011 (r221310) @@ -1404,9 +1404,12 @@ nfs_mknodrpc(struct vnode *dvp, struct v (void) nfscl_loadattrcache(&dvp, &dnfsva, NULL, NULL, 0, 1); if (!error) { newvp = NFSTOV(np); - if (attrflag) + if (attrflag != 0) { error = nfscl_loadattrcache(&newvp, &nfsva, NULL, NULL, 0, 1); + if (error != 0) + vput(newvp); + } } if (!error) { if ((cnp->cn_flags & MAKEENTRY)) @@ -1512,7 +1515,7 @@ again: } if (error) { if (newvp != NULL) { - vrele(newvp); + vput(newvp); newvp = NULL; } if (NFS_ISV34(dvp) && (fmode & O_EXCL) &&
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201105020049.p420nlfD014704>