xf86-video-r128: Branch 'master'

Matthieu Herrb herrb at kemper.freedesktop.org
Sat Jun 13 10:21:04 PDT 2009


 src/r128_driver.c |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 5d8a8df3aca2f14366946e48df9b674d7254ce04
Author: Matthieu Herrb <matthieu.herrb at laas.fr>
Date:   Sat Jun 13 19:20:24 2009 +0200

    Don't de-reference a NULL pointer in R128FreeScreen in the error path.
    
    If R128PreInit() failed, R128FreeRec() was already called and info
    will be NULL.

diff --git a/src/r128_driver.c b/src/r128_driver.c
index e3d7bb3..f42acb6 100644
--- a/src/r128_driver.c
+++ b/src/r128_driver.c
@@ -4337,6 +4337,8 @@ void R128FreeScreen(int scrnIndex, int flags)
     R128InfoPtr   info      = R128PTR(pScrn);
 
     R128TRACE(("R128FreeScreen\n"));
+    if (info == NULL)
+	return;
 #ifdef WITH_VGAHW
     if (info->VGAAccess && xf86LoaderCheckSymbol("vgaHWFreeHWRec"))
 	vgaHWFreeHWRec(pScrn);


More information about the xorg-commit mailing list