Permalink
Browse files

[droid] fix egl shutdown

Can't release a surface if there window is already destroyed
  • Loading branch information...
Cory Fields
Cory Fields committed Jul 18, 2012
1 parent 0bcd002 commit 41a71a8822d6de85f4c0a193248fa199c0b0003e
Showing with 2 additions and 1 deletion.
  1. +2 −1 xbmc/windowing/egl/WinEGLPlatformGeneric.cpp
@@ -318,7 +318,8 @@ bool CWinEGLPlatformGeneric::ReleaseSurface()
m_context = EGL_NO_CONTEXT;
}
- eglMakeCurrent(m_display, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT);
+ if (m_display != EGL_NO_DISPLAY)
+ eglMakeCurrent(m_display, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT);
return true;
}

0 comments on commit 41a71a8

Please sign in to comment.