mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-18 10:04:20 +03:00
lvcreate: fix error path return values
Return failing error code for return path, as 'return 0' in this case was returning success.
This commit is contained in:
parent
0fed9b0971
commit
b9f35e07db
@ -1750,21 +1750,21 @@ static int _lvcreate_single(struct cmd_context *cmd, const char *vg_name,
|
|||||||
goto_out;
|
goto_out;
|
||||||
|
|
||||||
if (seg_is_vdo(lp) && !_check_vdo_parameters(vg, lp, lcp))
|
if (seg_is_vdo(lp) && !_check_vdo_parameters(vg, lp, lcp))
|
||||||
return_0;
|
goto_out;
|
||||||
|
|
||||||
if (!_check_pool_parameters(cmd, vg, lp, lcp))
|
if (!_check_pool_parameters(cmd, vg, lp, lcp))
|
||||||
goto_out;
|
goto_out;
|
||||||
|
|
||||||
/* All types are checked */
|
/* All types are checked */
|
||||||
if (!_check_zero_parameters(cmd, lp))
|
if (!_check_zero_parameters(cmd, lp))
|
||||||
return_0;
|
goto_out;
|
||||||
|
|
||||||
if (!_update_extents_params(vg, lp, lcp))
|
if (!_update_extents_params(vg, lp, lcp))
|
||||||
goto_out;
|
goto_out;
|
||||||
|
|
||||||
if (seg_is_vdo(lp) && !check_vdo_constrains(cmd, (uint64_t)lp->extents * vg->extent_size,
|
if (seg_is_vdo(lp) && !check_vdo_constrains(cmd, (uint64_t)lp->extents * vg->extent_size,
|
||||||
lcp->virtual_size, &lp->vdo_params))
|
lcp->virtual_size, &lp->vdo_params))
|
||||||
return_0;
|
goto_out;
|
||||||
|
|
||||||
if (seg_is_thin(lp) && !_validate_internal_thin_processing(lp))
|
if (seg_is_thin(lp) && !_validate_internal_thin_processing(lp))
|
||||||
goto_out;
|
goto_out;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user