1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-10-27 18:55:19 +03:00

Remove assumption that --yes must be used only in --force mode

This is not only undocumented but is is also in violation with --help
documentation.

Using --yes without --force is useful in pvcreate when it detects
old signature.
This commit is contained in:
Milan Broz 2010-08-19 23:04:37 +00:00
parent 2d5e2b52ca
commit cca6ab596f
3 changed files with 1 additions and 10 deletions

View File

@ -1,6 +1,7 @@
Version 2.02.74 -
==================================
Simplify MD/swap signature detection in pvcreate and allow aborting.
Remove assumption that --yes must be used only in --force mode.
Version 2.02.73 - 18th August 2010
==================================

View File

@ -143,11 +143,6 @@ int pvremove(struct cmd_context *cmd, int argc, char **argv)
return EINVALID_CMD_LINE;
}
if (arg_count(cmd, yes_ARG) && !arg_count(cmd, force_ARG)) {
log_error("Option y can only be given with option f");
return EINVALID_CMD_LINE;
}
for (i = 0; i < argc; i++) {
r = pvremove_single(cmd, argv[i], NULL);
if (r > ret)

View File

@ -1344,11 +1344,6 @@ int pvcreate_params_validate(struct cmd_context *cmd,
return 0;
}
if (arg_count(cmd, yes_ARG) && !arg_count(cmd, force_ARG)) {
log_error("Option y can only be given with option f");
return 0;
}
pp->yes = arg_count(cmd, yes_ARG);
pp->force = arg_count(cmd, force_ARG);