1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-22 17:35:59 +03:00

fix to earlier checkin

This commit is contained in:
Alasdair Kergon 2008-01-16 19:40:42 +00:00
parent 17431cddac
commit c394e2c5b6

View File

@ -540,7 +540,7 @@ static int lvconvert_mirrors(struct cmd_context * cmd, struct logical_volume * l
* linear-to-mirror conversion. * linear-to-mirror conversion.
*/ */
original_lv = _original_lv(lv); original_lv = _original_lv(lv);
if (!seg->log_lv && !corelog) { if (!first_seg(original_lv)->log_lv && !corelog) {
if (!add_mirror_log(cmd, original_lv, 1, if (!add_mirror_log(cmd, original_lv, 1,
adjusted_mirror_region_size( adjusted_mirror_region_size(
lv->vg->extent_size, lv->vg->extent_size,
@ -548,7 +548,7 @@ static int lvconvert_mirrors(struct cmd_context * cmd, struct logical_volume * l
lp->region_size), lp->region_size),
lp->pvh, lp->alloc)) lp->pvh, lp->alloc))
return_0; return_0;
} else if (seg->log_lv && corelog) { } else if (first_seg(original_lv)->log_lv && corelog) {
if (!remove_mirror_log(cmd, original_lv, if (!remove_mirror_log(cmd, original_lv,
lp->pv_count ? lp->pvh : NULL)) lp->pv_count ? lp->pvh : NULL))
return_0; return_0;