[Patch] Dead code in mtd/maps/pci.c

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

 



hi,

this fixed coverity bug #12. The first two gotos
in the function still have the initial value for mtd set.
And the third goto just triggers for !mtd

Signed-off-by: Eric Sesterhenn <[email protected]>

--- linux-2.6.16-rc5-mm1/drivers/mtd/maps/pci.c.orig	2006-03-07 21:08:08.000000000 +0100
+++ linux-2.6.16-rc5-mm1/drivers/mtd/maps/pci.c	2006-03-07 21:08:23.000000000 +0100
@@ -334,9 +334,6 @@ mtd_pci_probe(struct pci_dev *dev, const
 	return 0;
 
 release:
-	if (mtd)
-		map_destroy(mtd);
-
 	if (map) {
 		map->exit(dev, map);
 		kfree(map);


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux