* [PATCH 11/15] tgafb: fix cmap memory leak
@ 2009-02-07 17:18 Andres Salomon
2009-02-09 17:09 ` [Linux-fbdev-devel] " Krzysztof Helt
0 siblings, 1 reply; 2+ messages in thread
From: Andres Salomon @ 2009-02-07 17:18 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-kernel, linux-fbdev-devel, adaplas
- fix cmap leak when register_framebuffer fails
Signed-off-by: Andres Salomon <dilinger@debian.org>
---
drivers/video/tgafb.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/drivers/video/tgafb.c b/drivers/video/tgafb.c
index 680642c..a86046f 100644
--- a/drivers/video/tgafb.c
+++ b/drivers/video/tgafb.c
@@ -1663,7 +1663,7 @@ tgafb_register(struct device *dev)
if (register_framebuffer(info) < 0) {
printk(KERN_ERR "tgafb: Could not register framebuffer\n");
ret = -EINVAL;
- goto err1;
+ goto err2;
}
if (tga_bus_pci) {
@@ -1682,6 +1682,8 @@ tgafb_register(struct device *dev)
return 0;
+ err2:
+ fb_dealloc_cmap(&info->cmap);
err1:
if (mem_base)
iounmap(mem_base);
--
1.5.6.5
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Linux-fbdev-devel] [PATCH 11/15] tgafb: fix cmap memory leak
2009-02-07 17:18 [PATCH 11/15] tgafb: fix cmap memory leak Andres Salomon
@ 2009-02-09 17:09 ` Krzysztof Helt
0 siblings, 0 replies; 2+ messages in thread
From: Krzysztof Helt @ 2009-02-09 17:09 UTC (permalink / raw)
To: Andres Salomon; +Cc: Andrew Morton, linux-fbdev-devel, linux-kernel, adaplas
On Sat, 7 Feb 2009 12:18:31 -0500
Andres Salomon <dilinger@queued.net> wrote:
>
> - fix cmap leak when register_framebuffer fails
>
> Signed-off-by: Andres Salomon <dilinger@debian.org>
> ---
Acked-by: Krzysztof Helt <krzysztof.h1@wp.pl>
> drivers/video/tgafb.c | 4 +++-
> 1 files changed, 3 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/video/tgafb.c b/drivers/video/tgafb.c
> index 680642c..a86046f 100644
> --- a/drivers/video/tgafb.c
> +++ b/drivers/video/tgafb.c
> @@ -1663,7 +1663,7 @@ tgafb_register(struct device *dev)
> if (register_framebuffer(info) < 0) {
> printk(KERN_ERR "tgafb: Could not register framebuffer\n");
> ret = -EINVAL;
> - goto err1;
> + goto err2;
> }
>
> if (tga_bus_pci) {
> @@ -1682,6 +1682,8 @@ tgafb_register(struct device *dev)
>
> return 0;
>
> + err2:
> + fb_dealloc_cmap(&info->cmap);
> err1:
> if (mem_base)
> iounmap(mem_base);
> --
> 1.5.6.5
>
>
> ------------------------------------------------------------------------------
> Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM)
> software. With Adobe AIR, Ajax developers can use existing skills and code to
> build responsive, highly engaging applications that combine the power of local
> resources and data with the reach of the web. Download the Adobe AIR SDK and
> Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com
> _______________________________________________
> Linux-fbdev-devel mailing list
> Linux-fbdev-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/linux-fbdev-devel
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-02-09 17:09 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-07 17:18 [PATCH 11/15] tgafb: fix cmap memory leak Andres Salomon
2009-02-09 17:09 ` [Linux-fbdev-devel] " Krzysztof Helt
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).