1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

lvmlockd: set failure flag for test mode

Set a failure flag when vg_read returns an error
for test mode.  The caller can segfault if there's
an error with no flag set.
This commit is contained in:
David Teigland 2019-10-04 10:07:24 -05:00
parent b20b23dfc6
commit a68258339d

View File

@ -3902,6 +3902,7 @@ static int _access_vg_lock_type(struct cmd_context *cmd, struct volume_group *vg
if (test_mode()) { if (test_mode()) {
log_error("Test mode is not yet supported with lock type %s.", vg->lock_type); log_error("Test mode is not yet supported with lock type %s.", vg->lock_type);
*failure |= FAILED_LOCK_TYPE;
return 0; return 0;
} }