Check for eglQueryString returning NULL

* This seems to happen sometimes during early startup on Android.
This commit is contained in:
baldurk
2018-07-11 14:58:48 +01:00
parent 504ebe5a1a
commit 64c6c1affc
+2 -1
View File
@@ -56,7 +56,8 @@ public:
bool IsYFlipped(EGLDisplay dpy, EGLSurface surface)
{
if(strstr(EGL.QueryString(dpy, EGL_EXTENSIONS), "ANGLE_surface_orientation"))
const char *extString = EGL.QueryString(dpy, EGL_EXTENSIONS);
if(extString && strstr(extString, "ANGLE_surface_orientation"))
{
// https://github.com/google/angle/blob/master/extensions/EGL_ANGLE_surface_orientation.txt
#define EGL_SURFACE_ORIENTATION_ANGLE 0x33A8