From f652f506734ff36069f5100766d557cd9b82d29e Mon Sep 17 00:00:00 2001 From: David 'Digit' Turner Date: Thu, 27 Mar 2014 11:07:20 +0100 Subject: emulator/opengl: Fix eglWaitGL implementation. The eglWaitEGL implementation didn't restore the previous bound API after calling eglWaitClient. This probably isn't a big concern for emugl correctness, but fixing this removes a compiler warning. See http://www.khronos.org/registry/egl/sdk/docs/man/xhtml/eglWaitGL.html Change-Id: I143ffeeefa01aff502d27d4e1d6f892f0d1efe5b --- emulator/opengl/host/libs/Translator/EGL/EglImp.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/emulator/opengl/host/libs/Translator/EGL/EglImp.cpp b/emulator/opengl/host/libs/Translator/EGL/EglImp.cpp index e31dea5..d88b473 100644 --- a/emulator/opengl/host/libs/Translator/EGL/EglImp.cpp +++ b/emulator/opengl/host/libs/Translator/EGL/EglImp.cpp @@ -858,7 +858,9 @@ EGLAPI EGLDisplay EGLAPIENTRY eglGetCurrentDisplay(void) { EGLAPI EGLBoolean EGLAPIENTRY eglWaitGL(void) { EGLenum api = eglQueryAPI(); eglBindAPI(EGL_OPENGL_ES_API); - return eglWaitClient(); + EGLBoolean ret = eglWaitClient(); + eglBindAPI(api); + return ret; } EGLAPI EGLBoolean EGLAPIENTRY eglWaitNative(EGLint engine) { -- cgit v1.1