All of lore.kernel.org
 help / color / mirror / Atom feed
* master - lvmlockd: set failure flag for test mode
@ 2019-10-04 15:10 David Teigland
  0 siblings, 0 replies; only message in thread
From: David Teigland @ 2019-10-04 15:10 UTC (permalink / raw)
  To: lvm-devel

Gitweb:        https://sourceware.org/git/?p=lvm2.git;a=commitdiff;h=a68258339da7e56910a2a3f6f98e43424ac219b6
Commit:        a68258339da7e56910a2a3f6f98e43424ac219b6
Parent:        b20b23dfc6bef6f0e468f8331b277e974d1fea12
Author:        David Teigland <teigland@redhat.com>
AuthorDate:    Fri Oct 4 10:07:24 2019 -0500
Committer:     David Teigland <teigland@redhat.com>
CommitterDate: Fri Oct 4 10:09:49 2019 -0500

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.
---
 lib/metadata/metadata.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/lib/metadata/metadata.c b/lib/metadata/metadata.c
index cf5c563..39544e6 100644
--- a/lib/metadata/metadata.c
+++ b/lib/metadata/metadata.c
@@ -3902,6 +3902,7 @@ static int _access_vg_lock_type(struct cmd_context *cmd, struct volume_group *vg
 
 	if (test_mode()) {
 		log_error("Test mode is not yet supported with lock type %s.", vg->lock_type);
+		*failure |= FAILED_LOCK_TYPE;
 		return 0;
 	}
 



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2019-10-04 15:10 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-04 15:10 master - lvmlockd: set failure flag for test mode David Teigland

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.