summaryrefslogtreecommitdiff
path: root/opengl/libagl/egl.cpp
diff options
context:
space:
mode:
author Kenny Root <kroot@google.com> 2010-06-01 19:55:01 -0700
committer Android (Google) Code Review <android-gerrit@google.com> 2010-06-01 19:55:01 -0700
commit89bc1395748a0a139db82adbf01166ed6fa79766 (patch)
tree75dc7b61d605847df777139daceefd72866c46b0 /opengl/libagl/egl.cpp
parentde56c27dab020bf85187c8bcfc6842cb31006c59 (diff)
parenta80ce06d4c54e43243073f8ceff024f9dda7140e (diff)
Merge "Add more error checking for ndc" into froyo
Diffstat (limited to 'opengl/libagl/egl.cpp')
-rw-r--r--opengl/libagl/egl.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/opengl/libagl/egl.cpp b/opengl/libagl/egl.cpp
index b6e0aae74ee8..7cb01d0e1a0b 100644
--- a/opengl/libagl/egl.cpp
+++ b/opengl/libagl/egl.cpp
@@ -1525,8 +1525,13 @@ EGLBoolean eglChooseConfig( EGLDisplay dpy, const EGLint *attrib_list,
}
if (ggl_unlikely(attrib_list==0)) {
- *num_config = 0;
- return EGL_TRUE;
+ /*
+ * A NULL attrib_list should be treated as though it was an empty
+ * one (terminated with EGL_NONE) as defined in
+ * section 3.4.1 "Querying Configurations" in the EGL specification.
+ */
+ static const EGLint dummy = EGL_NONE;
+ attrib_list = &dummy;
}
int numAttributes = 0;