[lvm-devel] [LVM2 PATCH] Fix 'lvconvert -s' to work again

Jun'ichi Nomura j-nomura at ce.jp.nec.com
Thu Aug 9 17:52:35 UTC 2007


Hi,

In current CVS head, 'lvconvert -s' doesn't work.
 # lvconvert -s testvg/lvol0 testvg/lvol1
 --snapshots argument cannot be mixed with --mirrors or --log
 lvconvert: Change logical volume layout

This is due to the lvconvert parameter check uses
'count' variable uninitialized for non-mirror case.
        int count;
...
        if (arg_count(cmd, log_ARG) || arg_count(cmd, mirrors_ARG))
                count = 1;
        count += arg_count(cmd, snapshot_ARG);

While the code around the _read_params() could be tidied up
some more, I hope this fix is included for now.

Thanks,
-- 
Jun'ichi Nomura, NEC Corporation of America
-------------- next part --------------
A non-text attachment was scrubbed...
Name: lvm2-lvconvert-fix-arg-mixture-check.patch
Type: text/x-patch
Size: 655 bytes
Desc: not available
URL: <http://listman.redhat.com/archives/lvm-devel/attachments/20070809/0a718685/attachment.bin>


More information about the lvm-devel mailing list