8966 Source file zfs_acl.c, function zfs_aclset_common contains a use after end of the lifetime of a local variable

illumos/illumos-gate@82693e09cc
82693e09cc

https://www.illumos.org/issues/8966

Reviewed by: Matt Ahrens <mahrens@delphix.com>
Reviewed by: Andriy Gapon <avg@FreeBSD.org>
Approved by: Richard Lowe <richlowe@richlowe.net>
Author: WHR <msl0000023508@gmail.com>
This commit is contained in:
Andriy Gapon 2018-02-21 14:12:29 +00:00
parent 79a23a6944
commit 771a769243
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/vendor-sys/illumos/dist/; revision=329710

View File

@ -1188,6 +1188,7 @@ zfs_aclset_common(znode_t *zp, zfs_acl_t *aclp, cred_t *cr, dmu_tx_t *tx)
sa_bulk_attr_t bulk[5];
uint64_t ctime[2];
int count = 0;
zfs_acl_phys_t acl_phys;
mode = zp->z_mode;
@ -1234,7 +1235,6 @@ zfs_aclset_common(znode_t *zp, zfs_acl_t *aclp, cred_t *cr, dmu_tx_t *tx)
} else { /* Painful legacy way */
zfs_acl_node_t *aclnode;
uint64_t off = 0;
zfs_acl_phys_t acl_phys;
uint64_t aoid;
if ((error = sa_lookup(zp->z_sa_hdl, SA_ZPL_ZNODE_ACL(zfsvfs),