Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 3 Jan 2011 00:40:13 +0000 (UTC)
From:      Rick Macklem <rmacklem@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r216898 - head/sys/fs/nfsserver
Message-ID:  <201101030040.p030eDLO063568@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rmacklem
Date: Mon Jan  3 00:40:13 2011
New Revision: 216898
URL: http://svn.freebsd.org/changeset/base/216898

Log:
  Fix the experimental NFS server so that it doesn't leak
  a reference count on the directory when creating device
  special files.
  
  MFC after:	2 weeks

Modified:
  head/sys/fs/nfsserver/nfs_nfsdport.c

Modified: head/sys/fs/nfsserver/nfs_nfsdport.c
==============================================================================
--- head/sys/fs/nfsserver/nfs_nfsdport.c	Mon Jan  3 00:33:32 2011	(r216897)
+++ head/sys/fs/nfsserver/nfs_nfsdport.c	Mon Jan  3 00:40:13 2011	(r216898)
@@ -857,8 +857,7 @@ nfsvno_mknod(struct nameidata *ndp, stru
 		    &ndp->ni_cnd, &nvap->na_vattr);
 		vput(ndp->ni_dvp);
 		nfsvno_relpathbuf(ndp);
-		if (error)
-			vrele(ndp->ni_startdir);
+		vrele(ndp->ni_startdir);
 		/*
 		 * Since VOP_MKNOD returns the ni_vp, I can't
 		 * see any reason to do the lookup.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201101030040.p030eDLO063568>