mirror of https://github.com/yshui/picom.git
backend/egl: don't call gl_deinit without a current context
Otherwise epoxy will fail with assertion error. Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
This commit is contained in:
parent
8655f383fb
commit
ca12415e22
|
@ -76,10 +76,9 @@ static void egl_release_image(backend_t *base, struct gl_texture *tex) {
|
|||
void egl_deinit(backend_t *base) {
|
||||
struct egl_data *gd = (void *)base;
|
||||
|
||||
gl_deinit(&gd->gl);
|
||||
|
||||
// Destroy EGL context
|
||||
if (gd->ctx != EGL_NO_CONTEXT) {
|
||||
gl_deinit(&gd->gl);
|
||||
eglMakeCurrent(gd->display, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT);
|
||||
eglDestroyContext(gd->display, gd->ctx);
|
||||
gd->ctx = EGL_NO_CONTEXT;
|
||||
|
|
Loading…
Reference in New Issue