mirror of
git://sourceware.org/git/lvm2.git
synced 2025-01-03 05:18:29 +03:00
cleanup: reoder rstatus init
In all error paths always initialize *rstatus.
This commit is contained in:
parent
b1dab26be0
commit
22e19cb354
@ -53,14 +53,14 @@ int exec_cmd(struct cmd_context *cmd, const char *const argv[],
|
|||||||
int status;
|
int status;
|
||||||
char buf[PATH_MAX * 2];
|
char buf[PATH_MAX * 2];
|
||||||
|
|
||||||
|
if (rstatus)
|
||||||
|
*rstatus = -1;
|
||||||
|
|
||||||
if (!argv[0]) {
|
if (!argv[0]) {
|
||||||
log_error(INTERNAL_ERROR "Missing command.");
|
log_error(INTERNAL_ERROR "Missing command.");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rstatus)
|
|
||||||
*rstatus = -1;
|
|
||||||
|
|
||||||
if (sync_needed)
|
if (sync_needed)
|
||||||
/* Flush ops and reset dm cookie */
|
/* Flush ops and reset dm cookie */
|
||||||
if (!sync_local_dev_names(cmd)) {
|
if (!sync_local_dev_names(cmd)) {
|
||||||
|
Loading…
Reference in New Issue
Block a user