Browse Source

vesafb: fix memory leak

When releasing framebuffer, free colourmap allocations.

Signed-off-by: Daniel J Blueman <daniel.blueman@gmail.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Daniel J Blueman 14 years ago
parent
commit
3e86f1d8e3
1 changed files with 1 additions and 0 deletions
  1. 1 0
      drivers/video/vesafb.c

+ 1 - 0
drivers/video/vesafb.c

@@ -175,6 +175,7 @@ static int vesafb_setcolreg(unsigned regno, unsigned red, unsigned green,
 
 static void vesafb_destroy(struct fb_info *info)
 {
+	fb_dealloc_cmap(&info->cmap);
 	if (info->screen_base)
 		iounmap(info->screen_base);
 	release_mem_region(info->apertures->ranges[0].base, info->apertures->ranges[0].size);