Mesa/u_mesa-CVE-2023-45913.patch

16 lines
602 B
Diff

src/glx/dri2_glx.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Index: mesa-23.3.4/src/glx/dri2_glx.c
===================================================================
--- mesa-23.3.4.orig/src/glx/dri2_glx.c
+++ mesa-23.3.4/src/glx/dri2_glx.c
@@ -1206,7 +1206,7 @@ dri2GetGlxDrawableFromXDrawableId(Displa
struct dri2_display *pdp = (struct dri2_display *) d->dri2Display;
__GLXDRIdrawable *pdraw;
- if (__glxHashLookup(pdp->dri2Hash, id, (void *) &pdraw) == 0)
+ if (pdp && __glxHashLookup(pdp->dri2Hash, id, (void *) &pdraw) == 0)
return pdraw;
return NULL;