Hey all,

As part of the cleanup in http://gerrit.openafs.org/#change,11331 I stumbled
upon a few things that probably should go here for review (thanks to Ben for
suggesting).

src/volser/vos.c:2155 says "if (entry.serverFlags[j] != ITSROVOL)", but that
field is a bitmask, so I think that that should be "if
(!(entry.serverFlags[j] & ITSROVOL))" (but also renamed to VLSF_ROVOL,
naturally) so that DeleteVolume will not skip RO volumes with other VLSF
bits asserted (e.g., VLSF_DONTUSE or VLSF_NEWREPSITE).  Does that seem
right?

src/volser/vsprocs.c:6217 says "entry.serverFlags[idx] = ITSBACKVOL;".
ITSBACKVOL and VLSF_BACKVOL are almost never otherwise used in the codebase,
and in particular the rest of the codebase seems to assume that the backup
volume has VLSF_RWVOL asserted, not VLSF_BACKVOL.  I believe that
CheckVolume is here trying to recreate a backup volume record that will get
detected as such, and so should read "entry.serverFlags[idx] = VLSF_RWVOL;".
Does that, too, seem right?

If these behavioral changes seem right, I'll move them out to their own
commits, rather than leaving them in 11331.

Thanks much.
--nwf;

Attachment: pgpU58Y4w7d1G.pgp
Description: PGP signature

Reply via email to