linux-fbdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] memory leak in imsttfb video driver
@ 2003-10-06 21:16 Felipe W Damasio
  0 siblings, 0 replies; only message in thread
From: Felipe W Damasio @ 2003-10-06 21:16 UTC (permalink / raw)
  To: lethal; +Cc: Linux Kernel Mailing List, linux-fbdev-devel

[-- Attachment #1: Type: text/plain, Size: 233 bytes --]

	Hi Paul,

	Patch against 2.6.0-test6.

	- Fixes 2 leaks in imsttfb driver: Frees the info struct imstt_par 
and releases the mem region if the device type is unknown.

	Found by smatch.

	Please consider applying,

	Thanks.

Felipe

[-- Attachment #2: imsttfb-leak.patch --]
[-- Type: text/plain, Size: 383 bytes --]

--- linux-2.6.0-test6/drivers/video/imsttfb.c.orig	2003-10-06 18:03:53.000000000 -0300
+++ linux-2.6.0-test6/drivers/video/imsttfb.c	2003-10-06 18:12:30.000000000 -0300
@@ -1495,6 +1495,8 @@
 		default:
 			printk(KERN_INFO "imsttfb: Device 0x%x unknown, "
 					 "contact maintainer.\n", pdev->device);
+			kfree(info);
+			release_mem_region(addr, size);
 			return -ENODEV;
 	}
 

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

only message in thread, other threads:[~2003-10-06 21:16 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2003-10-06 21:16 [PATCH] memory leak in imsttfb video driver Felipe W Damasio

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).