diff options
author | Matthieu Herrb <matthieu.herrb@laas.fr> | 2009-06-13 19:20:24 +0200 |
---|---|---|
committer | Matthieu Herrb <matthieu.herrb@laas.fr> | 2009-06-13 19:20:24 +0200 |
commit | 5d8a8df3aca2f14366946e48df9b674d7254ce04 (patch) | |
tree | 84407480da41d781b22f8c5a370da47fed333a16 /src/r128_driver.c | |
parent | 771c707eb2bba21b6013327bb62859c37be08673 (diff) |
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.
Diffstat (limited to 'src/r128_driver.c')
-rw-r--r-- | src/r128_driver.c | 2 |
1 files changed, 2 insertions, 0 deletions
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); |