From f6759c48886e96966a3180c3c656bf291833057c Mon Sep 17 00:00:00 2001 From: Ted McCabe Date: Mon, 14 May 2001 22:30:35 +0000 Subject: [PATCH] darwin-clear-va-flags-in-copyoutattrs-20010514 "I noticed that when I tried copying files out of AFS, I would often not be able to modify the destination files/dirs due to the user flags being non-zero (see man chflags). Turns out that not all of the fields of Darwin's struct vattr were being set in afs_CopyOutAttrs This patch clears the va_flags entry. I wasn't sure how the va_filerev and va_gen fields are precisely used, but since I wasn't noticing any trouble I could attribute to them, I left them unspecified. I suspect someone with more knowledge can say for sure. " --- src/afs/VNOPS/afs_vnop_attrs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/afs/VNOPS/afs_vnop_attrs.c b/src/afs/VNOPS/afs_vnop_attrs.c index 311f2161f..eb9c218fb 100644 --- a/src/afs/VNOPS/afs_vnop_attrs.c +++ b/src/afs/VNOPS/afs_vnop_attrs.c @@ -128,14 +128,14 @@ afs_CopyOutAttrs(avc, attrs) * Below return 0 (and not 1) blocks if the file is zero length. This conforms * better with the other filesystems that do return 0. */ -#ifdef AFS_OSF_ENV +#if defined(AFS_OSF_ENV) || defined(AFS_DARWIN_ENV) #ifdef va_size_rsv attrs->va_size_rsv = 0; #endif /* XXX do this */ /* attrs->va_gen = avc->m.DataVersion;*/ attrs->va_flags = 0; -#endif /* AFS_OSF_ENV */ +#endif /* AFS_OSF_ENV || AFS_DARWIN_ENV */ #if !defined(AFS_OSF_ENV) && !defined(AFS_DARWIN_ENV) && !defined(AFS_FBSD_ENV) #if !defined(AFS_HPUX_ENV) -- 2.39.5