mirror of https://gitlab.freedesktop.org/mesa/mesa
egl/dri: Don't invoke dri2_dpy->flush if it's NULL.
I'd like to test Mesa OpenGL ES along side with NVIDIA libGL drivers. But without this change, I get a NULL pointer dereference. Reviewed-by: Brian Paul <brianp@vmware.com>
This commit is contained in:
parent
d08cee5d80
commit
5048e69392
|
@ -976,7 +976,8 @@ dri2_wait_client(_EGLDriver *drv, _EGLDisplay *disp, _EGLContext *ctx)
|
|||
/* FIXME: If EGL allows frontbuffer rendering for window surfaces,
|
||||
* we need to copy fake to real here.*/
|
||||
|
||||
(*dri2_dpy->flush->flush)(dri2_surf->dri_drawable);
|
||||
if (dri2_dpy->flush != NULL)
|
||||
dri2_dpy->flush->flush(dri2_surf->dri_drawable);
|
||||
|
||||
return EGL_TRUE;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue