mirror of
git://sourceware.org/git/lvm2.git
synced 2025-03-10 16:58:47 +03:00
raid: check more cautious on region size changes
Add additional checks to avoid calling _region_size_change_requested() with bogus actual arguments.
This commit is contained in:
parent
77a7ed065f
commit
5f2c942000
@ -5810,7 +5810,7 @@ static int _region_size_change_requested(struct logical_volume *lv, int yes, con
|
||||
return_0;
|
||||
|
||||
/* CLI validation provides the check but be caucious... */
|
||||
if (seg_is_any_raid0(seg))
|
||||
if (!lv_is_raid(lv) || !seg || seg_is_any_raid0(seg))
|
||||
return_0;
|
||||
|
||||
if (region_size == seg->region_size) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user