From: Matthias Fuchs Date: Mon, 21 Apr 2008 09:19:04 +0000 (+0200) Subject: video: Add missing free for logo memory X-Git-Tag: v1.3.3-rc1~37^2 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=a49e0d177a0749614b316ec847fb623f09c82c07;p=u-boot video: Add missing free for logo memory This patch adds two missing free()s. Signed-off-by: Matthias Fuchs --- diff --git a/drivers/video/cfb_console.c b/drivers/video/cfb_console.c index 4f73067251..68b9861d41 100644 --- a/drivers/video/cfb_console.c +++ b/drivers/video/cfb_console.c @@ -849,6 +849,7 @@ int video_display_bitmap (ulong bmp_image, int x, int y) if (!((bmp->header.signature[0] == 'B') && (bmp->header.signature[1] == 'M'))) { printf ("Error: no valid bmp.gz image at %lx\n", bmp_image); + free(dst); return 1; } #else @@ -869,6 +870,10 @@ int video_display_bitmap (ulong bmp_image, int x, int y) if (compression != BMP_BI_RGB) { printf ("Error: compression type %ld not supported\n", compression); +#ifdef CONFIG_VIDEO_BMP_GZIP + if (dst) + free(dst); +#endif return 1; }