mirror of
git://sourceware.org/git/lvm2.git
synced 2024-12-21 13:34:40 +03:00
Reorder AND test condition
Take the easiest condition for checking first since they must apply all together, check local conditions first before doing more expensive tests.
This commit is contained in:
parent
3de08fc9de
commit
8542953f74
@ -1,5 +1,6 @@
|
||||
Version 2.02.89 -
|
||||
==================================
|
||||
Reorder prompt conditions for removal of active volumes.
|
||||
Avoid 'mda inconsistency' by properly registering UNLABELLED_PV flag (2.02.86).
|
||||
Fix --enable-static_link unless using --enable-dmeventd / --enable-udev_sync.
|
||||
Move gentoo MAKEDEV to /sbin in lvm2create_initrd.
|
||||
|
@ -3179,8 +3179,9 @@ int lv_remove_single(struct cmd_context *cmd, struct logical_volume *lv,
|
||||
if (!lv_check_not_in_use(cmd, lv, &info))
|
||||
return_0;
|
||||
|
||||
if (lv_is_active(lv) && (force == PROMPT) &&
|
||||
if ((force == PROMPT) &&
|
||||
lv_is_visible(lv) &&
|
||||
lv_is_active(lv) &&
|
||||
yes_no_prompt("Do you really want to remove active "
|
||||
"%slogical volume %s? [y/n]: ",
|
||||
vg_is_clustered(vg) ? "clustered " : "",
|
||||
|
Loading…
Reference in New Issue
Block a user