PERFORCE change 89741 for review

Christian S.J. Peron csjp at FreeBSD.org
Sun Jan 15 12:05:05 PST 2006


http://perforce.freebsd.org/chv.cgi?CH=89741

Change 89741 by csjp at csjp_xor on 2006/01/15 20:04:03

	Remove deallocations of the ucred here. The ucred will presist as
	as long as the NFS descriptor will. This simplifies the code.

Affected files ...

.. //depot/projects/trustedbsd/mac/sys/nfsserver/nfs_srvsock.c#24 edit

Differences ...

==== //depot/projects/trustedbsd/mac/sys/nfsserver/nfs_srvsock.c#24 (text+ko) ====

@@ -375,8 +375,6 @@
 		len = fxdr_unsigned(int, *tl);
 		if (len < 0 || len > RPCAUTH_UNIXGIDS) {
 			m_freem(mrep);
-			crfree(nd->nd_cr);
-			nd->nd_cr = NULL;
 			return (EBADRPC);
 		}
 		tl = nfsm_dissect_nonblock(u_int32_t *, (len + 2) * NFSX_UNSIGNED);
@@ -391,8 +389,6 @@
 		len = fxdr_unsigned(int, *++tl);
 		if (len < 0 || len > RPCAUTH_MAXSIZ) {
 			m_freem(mrep);
-			crfree(nd->nd_cr);
-			nd->nd_cr = NULL;
 			return (EBADRPC);
 		}
 		if (len > 0)
@@ -400,10 +396,6 @@
 	} else {
 		nd->nd_repstat = (NFSERR_AUTHERR | AUTH_REJECTCRED);
 		nd->nd_procnum = NFSPROC_NOOP;
-		if (nd->nd_cr != NULL) {
-			crfree(nd->nd_cr);
-			nd->nd_cr = NULL;
-		}
 		return (0);
 	}
 


More information about the p4-projects mailing list