From: Antonino A. Daplas Date: Sat, 11 Mar 2006 11:27:24 +0000 (-0800) Subject: [PATCH] imsttfb: Fix resource leak X-Git-Tag: v2.6.16-rc6~12 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=91bc89cf98f8aa83c64e14a8939d4f5d0790cf24;p=linux-2.6-omap-h63xx.git [PATCH] imsttfb: Fix resource leak The struct info and device resource may not be released in the driver's error path. Fix. Coverity Bug 671 Signed-off-by: Antonino Daplas Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/video/imsttfb.c b/drivers/video/imsttfb.c index ad416ae4759..7db42542eb1 100644 --- a/drivers/video/imsttfb.c +++ b/drivers/video/imsttfb.c @@ -1510,6 +1510,8 @@ imsttfb_probe(struct pci_dev *pdev, const struct pci_device_id *ent) default: printk(KERN_INFO "imsttfb: Device 0x%x unknown, " "contact maintainer.\n", pdev->device); + release_mem_region(addr, size); + framebuffer_release(info); return -ENODEV; }