All of lore.kernel.org
 help / color / mirror / Atom feed
* master - lvconvert: add extra check for existance of pointer
@ 2015-11-09  9:28 Zdenek Kabelac
  0 siblings, 0 replies; only message in thread
From: Zdenek Kabelac @ 2015-11-09  9:28 UTC (permalink / raw)
  To: lvm-devel

Gitweb:        http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=18fd0bd20ce1d4a7d2bd27b2c9981a402f9bcd2e
Commit:        18fd0bd20ce1d4a7d2bd27b2c9981a402f9bcd2e
Parent:        b83a20b80a1f2f239e5c8496e819edd039965a6c
Author:        Zdenek Kabelac <zkabelac@redhat.com>
AuthorDate:    Mon Nov 9 09:48:17 2015 +0100
Committer:     Zdenek Kabelac <zkabelac@redhat.com>
CommitterDate: Mon Nov 9 10:19:19 2015 +0100

lvconvert: add extra check for existance of pointer

Coverity here is not fully-in-picture - but please it
with validation of pointer which currently cannot be null,
since we always return at least empty string.
---
 tools/lvconvert.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/tools/lvconvert.c b/tools/lvconvert.c
index a7df26d..c6cea0d 100644
--- a/tools/lvconvert.c
+++ b/tools/lvconvert.c
@@ -2340,7 +2340,7 @@ static int _lvconvert_pool_repair(struct cmd_context *cmd,
 	struct pipe_data pdata;
 	FILE *f;
 
-	if (!thin_repair[0]) {
+	if (!thin_repair || !thin_repair[0]) {
 		log_error("Thin repair commnand is not configured. Repair is disabled.");
 		return 0; /* Checking disabled */
 	}



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

only message in thread, other threads:[~2015-11-09  9:28 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-11-09  9:28 master - lvconvert: add extra check for existance of pointer Zdenek Kabelac

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.