diff options
author | David Teigland <teigland@redhat.com> | 2022-07-05 17:08:00 -0500 |
---|---|---|
committer | David Teigland <teigland@redhat.com> | 2022-07-06 10:10:58 -0500 |
commit | 92b4fcf57f3c6d212d06b72b097e1a06e6efb84b (patch) | |
tree | 0374dbb21837fc5e051c5508c65b30b883069370 /tools/pvremove.c | |
parent | d0f94e763d6e6bca491c74cea93ec3062f32757e (diff) | |
download | lvm2-92b4fcf57f3c6d212d06b72b097e1a06e6efb84b.tar.gz |
exit with error when --devicesfile name doesn't exist
Diffstat (limited to 'tools/pvremove.c')
-rw-r--r-- | tools/pvremove.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/pvremove.c b/tools/pvremove.c index 2dfdbd016..5c39ee0c7 100644 --- a/tools/pvremove.c +++ b/tools/pvremove.c @@ -45,7 +45,8 @@ int pvremove(struct cmd_context *cmd, int argc, char **argv) clear_hint_file(cmd); - lvmcache_label_scan(cmd); + if (!lvmcache_label_scan(cmd)) + return_ECMD_FAILED; /* When forcibly clearing a PV we don't care about a VG lock. */ if (pp.force == DONT_PROMPT_OVERRIDE) |