From cd35aa9e2aec16d622177eeea1e1b3ec8aacdd45 Mon Sep 17 00:00:00 2001 From: Andrew Deason Date: Wed, 23 Dec 2020 12:44:35 -0600 Subject: [PATCH] afs: Fix XBSD check for VNOVAL va_uid Commit e86eb73e (obsd-vattrs-20040125) introduced an XBSD-specific check to detect some unchanged attributes. But the #ifdef for XBSD for the va_uid section was added in the middle of an HPUX-specific block by mistake. Move this #ifdef one level higher, so it's actually used on BSD platforms. Change-Id: I606f87f21d6c4830ed8bcf50abd6fb5807868ff5 Reviewed-on: https://gerrit.openafs.org/14473 Tested-by: BuildBot Reviewed-by: Cheyenne Wills Reviewed-by: Tim Creech Reviewed-by: Benjamin Kaduk --- 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 beb82975a6..0c2620ed0c 100644 --- a/src/afs/VNOPS/afs_vnop_attrs.c +++ b/src/afs/VNOPS/afs_vnop_attrs.c @@ -410,11 +410,11 @@ afs_VAttrToAS(struct vcache *avc, struct vattr *av, #elif defined(AFS_HPUX_ENV) #if defined(AFS_HPUX102_ENV) if (av->va_uid != UID_NO_CHANGE) { -#elif defined(AFS_XBSD_ENV) - if (av->va_uid != (uid_t)VNOVAL) { #else if (av->va_uid != ((unsigned short)-1)) { #endif +#elif defined(AFS_XBSD_ENV) + if (av->va_uid != (uid_t)VNOVAL) { #else if (av->va_uid != -1) { #endif /* AFS_LINUX22_ENV */