macOS can also set va_type
Reviewed-by: Ryan Moeller <ryan@iXsystems.com> Reviewed-by: Tony Nguyen <tony.nguyen@delphix.com> Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Jorgen Lundman <lundman@lundman.net> Closes #12357
This commit is contained in:
parent
02601d8aa4
commit
273730d5b5
|
@ -71,7 +71,7 @@ zfs_init_vattr(vattr_t *vap, uint64_t mask, uint64_t mode,
|
||||||
bzero(vap, sizeof (*vap));
|
bzero(vap, sizeof (*vap));
|
||||||
vap->va_mask = (uint_t)mask;
|
vap->va_mask = (uint_t)mask;
|
||||||
vap->va_mode = mode;
|
vap->va_mode = mode;
|
||||||
#ifdef __FreeBSD__
|
#if defined(__FreeBSD__) || defined(__APPLE__)
|
||||||
vap->va_type = IFTOVT(mode);
|
vap->va_type = IFTOVT(mode);
|
||||||
#endif
|
#endif
|
||||||
vap->va_uid = (uid_t)(IS_EPHEMERAL(uid)) ? -1 : uid;
|
vap->va_uid = (uid_t)(IS_EPHEMERAL(uid)) ? -1 : uid;
|
||||||
|
|
Loading…
Reference in New Issue