[PATCH] Coverity: Resource leak: fix return without free

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



---
 Assemble.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Assemble.c b/Assemble.c
index e83d550..123d44a 100644
--- a/Assemble.c
+++ b/Assemble.c
@@ -281,6 +281,8 @@ static int select_devices(struct mddev_dev *devlist,
 				st->ss->free_super(st);
 			dev_policy_free(pol);
 			domain_free(domains);
+			if (tst)
+				tst->ss->free_super(tst);
 			return -1;
 		}
 
-- 
2.13.7

--
To unsubscribe from this list: send the line "unsubscribe linux-raid" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux RAID Wiki]     [ATA RAID]     [Linux SCSI Target Infrastructure]     [Linux Block]     [Linux IDE]     [Linux SCSI]     [Linux Hams]     [Device Mapper]     [Device Mapper Cryptographics]     [Kernel]     [Linux Admin]     [Linux Net]     [GFS]     [RPM]     [git]     [Yosemite Forum]


  Powered by Linux