Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/cddl/osnet/dist/uts/common/fs/zfs Pass NetBSD VA_UT...
details: https://anonhg.NetBSD.org/src/rev/e752ee805e50
branches: trunk
changeset: 337287:e752ee805e50
user: riastradh <riastradh%NetBSD.org@localhost>
date: Thu Apr 09 20:18:28 2015 +0000
description:
Pass NetBSD VA_UTIMES_NULL through to ZFS as Solaris ATTR_UTIME.
Makes t_unpriv:zfs_times fail the wrong way instead of silently
allowing the change.
diffstat:
external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vnops.c | 5 ++++-
1 files changed, 4 insertions(+), 1 deletions(-)
diffs (25 lines):
diff -r 126e09c64e09 -r e752ee805e50 external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vnops.c
--- a/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vnops.c Thu Apr 09 19:51:13 2015 +0000
+++ b/external/cddl/osnet/dist/uts/common/fs/zfs/zfs_vnops.c Thu Apr 09 20:18:28 2015 +0000
@@ -5153,9 +5153,12 @@
xvattr_t xvap;
u_long fflags;
uint64_t zflags;
+ int flags = 0;
vattr_init_mask(vap);
vap->va_mask &= ~AT_NOSET;
+ if (ISSET(vap->va_vaflags, VA_UTIMES_NULL))
+ flags |= ATTR_UTIME;
xva_init(&xvap);
xvap.xva_vattr = *vap;
@@ -5216,7 +5219,7 @@
xvap.xva_xoptattrs.xoa_nodump);
#undef FLAG_CHANGE
}
- return (zfs_setattr(vp, (vattr_t *)&xvap, 0, cred, NULL));
+ return (zfs_setattr(vp, (vattr_t *)&xvap, flags, cred, NULL));
}
static int
Home |
Main Index |
Thread Index |
Old Index