renderer-egl: Clean up properly on exit

libvncclient-integration
Andri Yngvason 2022-06-29 15:49:57 +00:00
parent 40c4cd7aba
commit 1317e847b6
1 changed files with 3 additions and 0 deletions

View File

@ -222,7 +222,10 @@ void egl_finish(void)
glDeleteProgram(shader_program_ext);
if (shader_program)
glDeleteProgram(shader_program);
eglMakeCurrent(egl_display, EGL_NO_SURFACE, EGL_NO_SURFACE,
EGL_NO_CONTEXT);
eglDestroyContext(egl_display, egl_context);
eglTerminate(egl_display);
}
static inline void append_attr(EGLint* dst, int* i, EGLint name, EGLint value)