Modify nfsvno_fhtovp() to ensure that it always sets the credp

argument. Returning without credp set could result in a caller
	doing crfree() on garbage.

Reviewed by:	kan
Approved by:	kib (mentor)
This commit is contained in:
Rick Macklem 2009-05-11 18:45:04 +00:00
parent 56916f026c
commit 70839889c6
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=191998

View File

@ -2422,6 +2422,7 @@ nfsvno_fhtovp(struct mount *mp, fhandle_t *fhp, struct sockaddr *nam,
int error;
int numsecflavor, *secflavors;
*credp = NULL;
error = VFS_FHTOVP(mp, &fhp->fh_fid, vpp);
if (nam && !error) {
error = VFS_CHECKEXP(mp, nam, &exp->nes_exflag, credp,