A bug in report.c? WAS: [linux-lvm] vg attributes (vg_attr) in vgs program don't seem to match the man page
ben scott
benscott at nwlink.com
Mon Mar 26 22:47:20 UTC 2007
On Monday 26 March 2007 02:05:41 am Milan Broz wrote:
>
> See lib/report/report.c in sources for exact description,
>
> Short overview
> (note that some attributes are used for hidden volumes only which are parts
> of snapshot, mirror, etc...)
>
> VG attributes
>
> wz--n-
>
> |||||`- clustered [c|-]
> ||||
> ||||`-- allocation policy
> |||| (c)ontiguous,(C)ling,(n)ormal,(a)nywhere,(i)nherit
> |||
<From the LVM2.2.02.24 source>
The following lines in report.c seems to show that (c) will become (C) if the
lv is locked:
repstr[2] = _alloc_policy_char(lv->alloc);
if (lv->status & LOCKED)
repstr[2] = toupper(repstr[2]);
That is also what the man page claims. However the start of report.c show
this:
switch (alloc) {
case ALLOC_CONTIGUOUS:
return 'c';
case ALLOC_CLING:
return 'C';
case ALLOC_NORMAL:
return 'n';
case ALLOC_ANYWHERE:
return 'a';
default:
return 'i';
}
Isn't that a conflict, or am I reading this wrong? BTW I am not a professional
programmer nor do I play one on TV.
More information about the linux-lvm
mailing list