summaryrefslogtreecommitdiffstats
path: root/src/egl/main/eglcurrent.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/egl/main/eglcurrent.h')
-rw-r--r--src/egl/main/eglcurrent.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/egl/main/eglcurrent.h b/src/egl/main/eglcurrent.h
index 6c203be0729..1e386acdafb 100644
--- a/src/egl/main/eglcurrent.h
+++ b/src/egl/main/eglcurrent.h
@@ -56,7 +56,6 @@ extern "C" {
*/
struct _egl_thread_info
{
- _EGLThreadInfo *Next; /* used to link threads */
EGLint LastError;
_EGLContext *CurrentContexts[_EGL_API_NUM_APIS];
/* use index for fast access to current context */
@@ -65,6 +64,16 @@ struct _egl_thread_info
/**
+ * Return true if a client API enum is recognized.
+ */
+static inline EGLBoolean
+_eglIsApiValid(EGLenum api)
+{
+ return (api >= _EGL_API_FIRST_API && api <= _EGL_API_LAST_API);
+}
+
+
+/**
* Convert a client API enum to an index, for use by thread info.
* The client API enum is assumed to be valid.
*/