svn commit: r190220 - head/sys/nfsclient

Robert Watson rwatson at FreeBSD.org
Sat Mar 21 14:49:08 PDT 2009


Author: rwatson
Date: Sat Mar 21 21:49:07 2009
New Revision: 190220
URL: http://svn.freebsd.org/changeset/base/190220

Log:
  In nfs_request(), always exit using the nfsmout label once we're
  definitely doing an NFSv2 or NFSv3 RPC, rather than sometimes doing
  so and sometimes not.  This makes it easier to add a DTrace return
  probe at a single point in the function.
  
  MFC after:	1 week

Modified:
  head/sys/nfsclient/nfs_krpc.c

Modified: head/sys/nfsclient/nfs_krpc.c
==============================================================================
--- head/sys/nfsclient/nfs_krpc.c	Sat Mar 21 21:37:53 2009	(r190219)
+++ head/sys/nfsclient/nfs_krpc.c	Sat Mar 21 21:49:07 2009	(r190220)
@@ -493,11 +493,8 @@ tryagain:
 		error = EACCES;
 	}
 	md = mrep;
-	if (error) {
-		m_freem(mreq);
-		AUTH_DESTROY(auth);
-		return (error);
-	}
+	if (error)
+		goto nfsmout;
 
 	KASSERT(mrep != NULL, ("mrep shouldn't be NULL if no error\n"));
 
@@ -535,9 +532,7 @@ tryagain:
 			error |= NFSERR_RETERR;
 		} else
 			m_freem(mrep);
-		m_freem(mreq);
-		AUTH_DESTROY(auth);
-		return (error);
+		goto nfsmout;
 	}
 
 	m_freem(mreq);


More information about the svn-src-all mailing list