audit: plug FILEDESC_LOCK leak in audit_canon_path.

MFC after:	3 days
This commit is contained in:
Mateusz Guzik 2014-03-21 01:30:33 +00:00
parent 8b3f42d52d
commit 00b85f6218
1 changed files with 1 additions and 0 deletions

View File

@ -497,6 +497,7 @@ audit_canon_path(struct thread *td, int dirfd, char *path, char *cpath)
/* 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);