From: Jeffrey Altman Date: Sat, 5 Jan 2008 22:19:12 +0000 (+0000) Subject: windows-follow-backup-path-20080105 X-Git-Tag: BP-openafs-windows-kdfs-ifs~232 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=d27e82c8e2dcdf81ce8e8e6e849828881256f5fc;p=packages%2Fo%2Fopenafs.git windows-follow-backup-path-20080105 LICENSE MIT parens are required in order to get the desired behavior --- diff --git a/src/WINNT/afsd/cm_vnodeops.c b/src/WINNT/afsd/cm_vnodeops.c index 3bd1f3fbc..c32487541 100644 --- a/src/WINNT/afsd/cm_vnodeops.c +++ b/src/WINNT/afsd/cm_vnodeops.c @@ -1138,9 +1138,11 @@ long cm_FollowMountPoint(cm_scache_t *scp, cm_scache_t *dscp, cm_user_t *userp, * volume for the target, then use the .backup of the target * instead of the read-write. */ - if (cm_followBackupPath && targetType == RWVOL && - (scp->flags & CM_SCACHEFLAG_RO|CM_SCACHEFLAG_PURERO) == CM_SCACHEFLAG_RO && - volp->bk.ID != 0) { + if (cm_followBackupPath && + volp->bk.ID != 0 && + (dscp->flags & (CM_SCACHEFLAG_RO|CM_SCACHEFLAG_PURERO)) == CM_SCACHEFLAG_RO && + (targetType == RWVOL || targetType == ROVOL && volp->ro.ID == 0) + ) { targetType = BACKVOL; } /* if the mt pt is in a read-only volume (not just a