diff options
author | David Teigland <teigland@redhat.com> | 2017-04-27 12:13:09 -0500 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2017-04-27 13:25:41 -0500 |
commit | 4f9ff14508084789c731e99d8921c052da694319 (patch) | |
tree | 49c7961c0adba15b574754f2b85a7e622f5ea8c8 /tools/pvresize.c | |
parent | 5cf51fb2f74ad43a2555bc391cf069caa1d99775 (diff) | |
download | lvm2-4f9ff14508084789c731e99d8921c052da694319.tar.gz |
pvcreate: add prompt when setting dev size
If the device size does not match the size requested
by --setphysicalvolumesize, then prompt the user.
Make the pvcreate checking/prompting code handle
multiple prompts for the same device, since the
new prompt can be in addition to the existing
prompt when the PV is in a VG.
Diffstat (limited to 'tools/pvresize.c')
-rw-r--r-- | tools/pvresize.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/pvresize.c b/tools/pvresize.c index 1de170906..8a65952e5 100644 --- a/tools/pvresize.c +++ b/tools/pvresize.c @@ -72,13 +72,13 @@ int pvresize(struct cmd_context *cmd, int argc, char **argv) goto out; } - if (arg_sign_value(cmd, physicalvolumesize_ARG, SIGN_NONE) == SIGN_MINUS) { + if (arg_sign_value(cmd, setphysicalvolumesize_ARG, SIGN_NONE) == SIGN_MINUS) { log_error("Physical volume size may not be negative"); ret = EINVALID_CMD_LINE; goto out; } - params.new_size = arg_uint64_value(cmd, physicalvolumesize_ARG, + params.new_size = arg_uint64_value(cmd, setphysicalvolumesize_ARG, UINT64_C(0)); params.done = 0; |