summaryrefslogtreecommitdiff
path: root/fb/fboverlay.c
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2011-04-04 11:57:39 -0700
committerKeith Packard <keithp@keithp.com>2011-04-04 11:57:39 -0700
commitc9d89cec1407550cb2568f4cef146c93607bbae6 (patch)
treef304c31842697512b659b0fa364f7582309d5210 /fb/fboverlay.c
parenta52049de2f846fe984d4db5ac8d2c1826c7b2d0b (diff)
parentbc61787a20e7683cbc4dfa45fe855da98a8c0cd0 (diff)
Merge remote-tracking branch 'vignatti/for-keith'
Diffstat (limited to 'fb/fboverlay.c')
-rw-r--r--fb/fboverlay.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/fb/fboverlay.c b/fb/fboverlay.c
index 61eaaa3f9..255cc23c1 100644
--- a/fb/fboverlay.c
+++ b/fb/fboverlay.c
@@ -384,12 +384,16 @@ fbOverlayFinishScreenInit(ScreenPtr pScreen,
if (!fbInitVisuals (&visuals, &depths, &nvisuals, &ndepths, &depth1,
&defaultVisual, ((unsigned long)1<<(bpp1-1)) |
- ((unsigned long)1<<(bpp2-1)), 8))
+ ((unsigned long)1<<(bpp2-1)), 8)) {
+ free(pScrPriv);
return FALSE;
+ }
if (! miScreenInit(pScreen, 0, xsize, ysize, dpix, dpiy, 0,
depth1, ndepths, depths,
- defaultVisual, nvisuals, visuals))
+ defaultVisual, nvisuals, visuals)) {
+ free(pScrPriv);
return FALSE;
+ }
/* MI thinks there's no frame buffer */
#ifdef MITSHM
ShmRegisterFbFuncs(pScreen);