Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Apr 2009 16:18:40 GMT
From:      Edward Tomasz Napierala <trasz@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 161331 for review
Message-ID:  <200904291618.n3TGIeP7010381@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=161331

Change 161331 by trasz@trasz_victim on 2009/04/29 16:17:53

	Last IFC brought in acl_alloc() that behaves in a slightly different
	way - it does no longer clear the memory by default.  Fix the code
	so that it doesn't trip on assertions.

Affected files ...

.. //depot/projects/soc2008/trasz_nfs4acl/sys/kern/subr_acl_nfs4.c#40 edit
.. //depot/projects/soc2008/trasz_nfs4acl/sys/ufs/ufs/ufs_vnops.c#27 edit

Differences ...

==== //depot/projects/soc2008/trasz_nfs4acl/sys/kern/subr_acl_nfs4.c#40 (text+ko) ====

@@ -1015,7 +1015,7 @@
 	 *      critical for performance to not use EA when they are not
 	 *      needed.
 	 */
-	tmpaclp = acl_alloc(M_WAITOK);
+	tmpaclp = acl_alloc(M_WAITOK | M_ZERO);
 	acl_nfs4_sync_mode_from_acl(&tmpmode, aclp);
 	acl_nfs4_sync_acl_from_mode(tmpaclp, tmpmode, file_owner_id);
 	trivial = _acls_are_equal(aclp, tmpaclp);

==== //depot/projects/soc2008/trasz_nfs4acl/sys/ufs/ufs/ufs_vnops.c#27 (text+ko) ====

@@ -1475,7 +1475,7 @@
 	struct acl *parent_aclp, *child_aclp;
 
 	parent_aclp = acl_alloc(M_WAITOK);
-	child_aclp = acl_alloc(M_WAITOK);
+	child_aclp = acl_alloc(M_WAITOK | M_ZERO);
 
 	error = VOP_GETACL(dvp, ACL_TYPE_NFS4, parent_aclp, cred, td);
 	if (error)



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200904291618.n3TGIeP7010381>