svn commit: r225282 - stable/8/sys/ufs/ufs

Andrey V. Elsukov ae at FreeBSD.org
Wed Aug 31 06:47:40 UTC 2011


Author: ae
Date: Wed Aug 31 06:47:39 2011
New Revision: 225282
URL: http://svn.freebsd.org/changeset/base/225282

Log:
  MFC r225104:
    Fix lock leak.
  
    Reported by:	Alex Lyashkov

Modified:
  stable/8/sys/ufs/ufs/ufs_extattr.c
Directory Properties:
  stable/8/sys/   (props changed)
  stable/8/sys/amd64/include/xen/   (props changed)
  stable/8/sys/cddl/contrib/opensolaris/   (props changed)
  stable/8/sys/contrib/dev/acpica/   (props changed)
  stable/8/sys/contrib/pf/   (props changed)

Modified: stable/8/sys/ufs/ufs/ufs_extattr.c
==============================================================================
--- stable/8/sys/ufs/ufs/ufs_extattr.c	Wed Aug 31 06:35:50 2011	(r225281)
+++ stable/8/sys/ufs/ufs/ufs_extattr.c	Wed Aug 31 06:47:39 2011	(r225282)
@@ -1031,14 +1031,14 @@ vop_setextattr {
 	struct ufsmount *ump = VFSTOUFS(mp); 
 	int error;
 
-	ufs_extattr_uepm_lock(ump, ap->a_td);
-
 	/*
 	 * XXX: No longer a supported way to delete extended attributes.
 	 */
 	if (ap->a_uio == NULL)
 		return (EINVAL);
 
+	ufs_extattr_uepm_lock(ump, ap->a_td);
+
 	error = ufs_extattr_set(ap->a_vp, ap->a_attrnamespace, ap->a_name,
 	    ap->a_uio, ap->a_cred, ap->a_td);
 


More information about the svn-src-stable mailing list