Skip to contentSkip to conversation

master - cleanup: drop unneeded test

PATCH Zdenek Kabelac 1 participant 1 message Feb 25, 2016

lore
Share & tools
lore
#0 lore raw
Gitweb:        http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=1a9f743eefbe8d86f6a23838789c21136f02cdcd
Commit:        1a9f743eefbe8d86f6a23838789c21136f02cdcd
Parent:        e9b523e3044b83fc1a919f8a07a85d169c7d4d55
Author:        Zdenek Kabelac <[email protected]>
AuthorDate:    Thu Feb 25 16:51:14 2016 +0100
Committer:     Zdenek Kabelac <[email protected]>
CommitterDate: Thu Feb 25 23:30:25 2016 +0100

cleanup: drop unneeded test

dmfree tests for NULL

---
 lib/cache/lvmcache.c |    4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)
lib/cache/lvmcache.c +1 -3
index c28460e..b1e53e2 100644
@@ -1177,9 +1177,7 @@ static int _free_vginfo(struct lvmcache_vginfo *vginfo)
 			vginfo2 = vginfo2->next;
 		}
 
-	if (vginfo->system_id)
-		dm_free(vginfo->system_id);
-
+	dm_free(vginfo->system_id);
 	dm_free(vginfo->vgname);
 	dm_free(vginfo->creation_host);