svn commit: r263458 - head/sys/security/audit

Mateusz Guzik mjg at FreeBSD.org
Fri Mar 21 01:30:34 UTC 2014


Author: mjg
Date: Fri Mar 21 01:30:33 2014
New Revision: 263458
URL: http://svnweb.freebsd.org/changeset/base/263458

Log:
  audit: plug FILEDESC_LOCK leak in audit_canon_path.
  
  MFC after:	3 days

Modified:
  head/sys/security/audit/audit_bsm_klib.c

Modified: head/sys/security/audit/audit_bsm_klib.c
==============================================================================
--- head/sys/security/audit/audit_bsm_klib.c	Fri Mar 21 00:56:56 2014	(r263457)
+++ head/sys/security/audit/audit_bsm_klib.c	Fri Mar 21 01:30:33 2014	(r263458)
@@ -497,6 +497,7 @@ audit_canon_path(struct thread *td, int 
 			/* XXX: fgetvp() that vhold()s vnode instead of vref()ing it would be better */
 			error = fgetvp(td, dirfd, NULL, &cvnp);
 			if (error) {
+				FILEDESC_SUNLOCK(fdp);
 				cpath[0] = '\0';
 				if (rvnp != NULL)
 					vdrop(rvnp);


More information about the svn-src-head mailing list