cedric pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=84c6d3332e2243b6074c995c05c8b50e29cefb4d

commit 84c6d3332e2243b6074c995c05c8b50e29cefb4d
Author: Cedric BAIL <ced...@osg.samsung.com>
Date:   Fri Aug 25 10:52:26 2017 -0700

    evas: remove unused engine data from error set/get code.
---
 src/modules/evas/engines/gl_common/evas_gl_api.c   |  2 +-
 .../evas/engines/gl_common/evas_gl_api_ext.c       | 10 ++--
 .../evas/engines/gl_common/evas_gl_api_gles1.c     |  4 +-
 .../evas/engines/gl_common/evas_gl_common.h        |  4 +-
 src/modules/evas/engines/gl_common/evas_gl_core.c  | 50 ++++++++--------
 src/modules/evas/engines/gl_generic/evas_engine.c  |  2 +-
 src/modules/evas/engines/gl_x11/evas_engine.c      | 70 +++++++++++-----------
 7 files changed, 71 insertions(+), 71 deletions(-)

diff --git a/src/modules/evas/engines/gl_common/evas_gl_api.c 
b/src/modules/evas/engines/gl_common/evas_gl_api.c
index 25d5d6aed4..ceaab2bc9f 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_api.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_api.c
@@ -1357,7 +1357,7 @@ _evgl_glGetString(GLenum name)
      {
         ERR("Current context is NULL, not calling glGetString");
         // This sets evas_gl_error_get instead of eglGetError...
-        evas_gl_common_error_set(NULL, EVAS_GL_BAD_CONTEXT);
+        evas_gl_common_error_set(EVAS_GL_BAD_CONTEXT);
         return NULL;
      }
 
diff --git a/src/modules/evas/engines/gl_common/evas_gl_api_ext.c 
b/src/modules/evas/engines/gl_common/evas_gl_api_ext.c
index 1169e79922..4c63761ae5 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_api_ext.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_api_ext.c
@@ -139,7 +139,7 @@ _evgl_egl_display_get(const char *function, Evas_GL *evgl)
    if (!evgl_engine || !evgl_engine->funcs || !evgl_engine->funcs->display_get)
      {
         ERR("%s: Invalid Engine... (Can't acccess EGL Display)\n", function);
-        evas_gl_common_error_set(NULL, EVAS_GL_BAD_DISPLAY);
+        evas_gl_common_error_set(EVAS_GL_BAD_DISPLAY);
         return EGL_NO_DISPLAY;
      }
 
@@ -147,7 +147,7 @@ _evgl_egl_display_get(const char *function, Evas_GL *evgl)
      {
         if (evgl) goto fallback;
         ERR("%s: Unable to execute GL command. Error retrieving tls", 
function);
-        evas_gl_common_error_set(NULL, EVAS_GL_NOT_INITIALIZED);
+        evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return EGL_NO_DISPLAY;
      }
 
@@ -155,7 +155,7 @@ _evgl_egl_display_get(const char *function, Evas_GL *evgl)
      {
         if (evgl) goto fallback;
         ERR("%s: no current engine set; ensure you've called 
evas_gl_make_current()", function);
-        evas_gl_common_error_set(NULL, EVAS_GL_NOT_INITIALIZED);
+        evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return EGL_NO_DISPLAY;
      }
 
@@ -238,7 +238,7 @@ _evgl_evasglCreateImageForContext(Evas_GL *evasgl, 
Evas_GL_Context *evasctx,
    if (!dpy || !evasgl)
      {
         ERR("Evas_GL can not be NULL here.");
-        evas_gl_common_error_set(NULL, EVAS_GL_BAD_DISPLAY);
+        evas_gl_common_error_set(EVAS_GL_BAD_DISPLAY);
         return NULL;
      }
 
@@ -254,7 +254,7 @@ _evgl_evasglDestroyImage(EvasGLImage image)
    if (!img)
      {
         ERR("EvasGLImage is NULL.");
-        evas_gl_common_error_set(NULL, EVAS_GL_BAD_PARAMETER);
+        evas_gl_common_error_set(EVAS_GL_BAD_PARAMETER);
         return;
      }
 
diff --git a/src/modules/evas/engines/gl_common/evas_gl_api_gles1.c 
b/src/modules/evas/engines/gl_common/evas_gl_api_gles1.c
index 0619c037ea..7117751156 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_api_gles1.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_api_gles1.c
@@ -1120,14 +1120,14 @@ _evgl_gles1_glGetString(GLenum name)
      {
         ERR("Current context is NULL, not calling glGetString");
         // This sets evas_gl_error_get instead of glGetError...
-        evas_gl_common_error_set(NULL, EVAS_GL_BAD_CONTEXT);
+        evas_gl_common_error_set(EVAS_GL_BAD_CONTEXT);
         return NULL;
      }
 
    if (rsc->current_ctx->version != EVAS_GL_GLES_1_X)
      {
         ERR("Invalid context version %d", (int) rsc->current_ctx->version);
-        evas_gl_common_error_set(NULL, EVAS_GL_BAD_MATCH);
+        evas_gl_common_error_set(EVAS_GL_BAD_MATCH);
         return NULL;
      }
 
diff --git a/src/modules/evas/engines/gl_common/evas_gl_common.h 
b/src/modules/evas/engines/gl_common/evas_gl_common.h
index d9deb990de..6124cf8da0 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_common.h
+++ b/src/modules/evas/engines/gl_common/evas_gl_common.h
@@ -564,8 +564,8 @@ EAPI void         
evas_gl_preload_render_unlock(evas_gl_make_current_cb make_cur
 EAPI void         evas_gl_preload_render_relax(evas_gl_make_current_cb 
make_current, void *engine_data);
 EAPI void         evas_gl_symbols(void *(*GetProcAddress)(const char *name), 
const char *extsn);
 
-EAPI void         evas_gl_common_error_set(void *data, int error_enum);
-EAPI int          evas_gl_common_error_get(void *data);
+EAPI void         evas_gl_common_error_set(int error_enum);
+EAPI int          evas_gl_common_error_get(void);
 EAPI void        *evas_gl_common_current_context_get(void);
 
 typedef int (*Evas_GL_Preload)(void);
diff --git a/src/modules/evas/engines/gl_common/evas_gl_core.c 
b/src/modules/evas/engines/gl_common/evas_gl_core.c
index c4d3541b4f..bb80888518 100644
--- a/src/modules/evas/engines/gl_common/evas_gl_core.c
+++ b/src/modules/evas/engines/gl_common/evas_gl_core.c
@@ -1782,7 +1782,7 @@ _evgl_direct_enabled(void)
 }
 
 EAPI void
-evas_gl_common_error_set(void *data EINA_UNUSED, int error_enum)
+evas_gl_common_error_set(int error_enum)
 {
    EVGL_Resource *rsc;
 
@@ -1796,7 +1796,7 @@ evas_gl_common_error_set(void *data EINA_UNUSED, int 
error_enum)
 }
 
 EAPI int
-evas_gl_common_error_get(void *data EINA_UNUSED)
+evas_gl_common_error_get(void)
 {
    EVGL_Resource *rsc;
 
@@ -2004,7 +2004,7 @@ evgl_surface_create(void *eng_data, Evas_GL_Config *cfg, 
int w, int h)
    if (!evgl_engine)
      {
         ERR("Invalid EVGL Engine!");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_ACCESS);
+        evas_gl_common_error_set(EVAS_GL_BAD_ACCESS);
         return NULL;
      }
    dbg = evgl_engine->api_debug_mode;
@@ -2012,7 +2012,7 @@ evgl_surface_create(void *eng_data, Evas_GL_Config *cfg, 
int w, int h)
    if (!cfg)
      {
         ERR("Invalid Config!");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_CONFIG);
+        evas_gl_common_error_set(EVAS_GL_BAD_CONFIG);
         return NULL;
      }
 
@@ -2021,7 +2021,7 @@ evgl_surface_create(void *eng_data, Evas_GL_Config *cfg, 
int w, int h)
      {
         ERR("Requested surface size [%d, %d] is greater than max supported 
size [%d, %d]",
              w, h, evgl_engine->caps.max_w, evgl_engine->caps.max_h);
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_PARAMETER);
+        evas_gl_common_error_set(EVAS_GL_BAD_PARAMETER);
         return NULL;
      }
 
@@ -2030,7 +2030,7 @@ evgl_surface_create(void *eng_data, Evas_GL_Config *cfg, 
int w, int h)
    if (!sfc)
      {
         ERR("Surface allocation failed.");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_ALLOC);
+        evas_gl_common_error_set(EVAS_GL_BAD_ALLOC);
         goto error;
      }
 
@@ -2059,7 +2059,7 @@ evgl_surface_create(void *eng_data, Evas_GL_Config *cfg, 
int w, int h)
    if (!_internal_config_set(eng_data, sfc, cfg))
      {
         ERR("Unsupported Format!");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_CONFIG);
+        evas_gl_common_error_set(EVAS_GL_BAD_CONFIG);
         goto error;
      }
    sfc->cfg = cfg;
@@ -2092,7 +2092,7 @@ evgl_pbuffer_surface_create(void *eng_data, 
Evas_GL_Config *cfg,
    if (!evgl_engine)
      {
         ERR("Invalid EVGL Engine!");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_ACCESS);
+        evas_gl_common_error_set(EVAS_GL_BAD_ACCESS);
         return NULL;
      }
    dbg = evgl_engine->api_debug_mode;
@@ -2100,14 +2100,14 @@ evgl_pbuffer_surface_create(void *eng_data, 
Evas_GL_Config *cfg,
    if (!cfg)
      {
         ERR("Invalid Config!");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_CONFIG);
+        evas_gl_common_error_set(EVAS_GL_BAD_CONFIG);
         return NULL;
      }
 
    if (!evgl_engine->funcs->pbuffer_surface_create)
      {
         ERR("Engine can not create PBuffers");
-        evas_gl_common_error_set(eng_data, EVAS_GL_NOT_INITIALIZED);
+        evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return NULL;
      }
 
@@ -2116,7 +2116,7 @@ evgl_pbuffer_surface_create(void *eng_data, 
Evas_GL_Config *cfg,
    if (!sfc)
      {
         ERR("Surface allocation failed.");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_ALLOC);
+        evas_gl_common_error_set(EVAS_GL_BAD_ALLOC);
         goto error;
      }
 
@@ -2135,7 +2135,7 @@ evgl_pbuffer_surface_create(void *eng_data, 
Evas_GL_Config *cfg,
         if (!_internal_config_set(eng_data, sfc, cfg))
           {
              ERR("Unsupported Format!");
-             evas_gl_common_error_set(eng_data, EVAS_GL_BAD_CONFIG);
+             evas_gl_common_error_set(EVAS_GL_BAD_CONFIG);
              goto error;
           }
      }
@@ -2304,14 +2304,14 @@ evgl_context_create(void *eng_data, EVGL_Context 
*share_ctx,
    if (!evgl_engine)
      {
         ERR("Invalid EVGL Engine!");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_ACCESS);
+        evas_gl_common_error_set(EVAS_GL_BAD_ACCESS);
         return NULL;
      }
 
    if ((version < EVAS_GL_GLES_1_X) || (version > EVAS_GL_GLES_3_X))
      {
         ERR("Invalid context version number %d", version);
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_PARAMETER);
+        evas_gl_common_error_set(EVAS_GL_BAD_PARAMETER);
         return NULL;
      }
 
@@ -2323,7 +2323,7 @@ evgl_context_create(void *eng_data, EVGL_Context 
*share_ctx,
    if (!ctx)
      {
         ERR("Error allocating context object.");
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_ALLOC);
+        evas_gl_common_error_set(EVAS_GL_BAD_ALLOC);
         return NULL;
      }
 
@@ -2467,8 +2467,8 @@ evgl_make_current(void *eng_data, EVGL_Surface *sfc, 
EVGL_Context *ctx)
    if ( (!evgl_engine) || ((sfc) && (!ctx)) )
      {
         ERR("Invalid Input: Engine: %p, Surface: %p, Context: %p", 
evgl_engine, sfc, ctx);
-        if (!evgl_engine) evas_gl_common_error_set(eng_data, 
EVAS_GL_NOT_INITIALIZED);
-        if (!ctx) evas_gl_common_error_set(eng_data, EVAS_GL_BAD_CONTEXT);
+        if (!evgl_engine) evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
+        if (!ctx) evas_gl_common_error_set(EVAS_GL_BAD_CONTEXT);
         return 0;
      }
 
@@ -2548,7 +2548,7 @@ evgl_make_current(void *eng_data, EVGL_Surface *sfc, 
EVGL_Context *ctx)
    if (!_internal_resource_make_current(eng_data, sfc, ctx))
      {
         ERR("Error doing a make current with internal surface. Context: %p", 
ctx);
-        evas_gl_common_error_set(eng_data, EVAS_GL_BAD_CONTEXT);
+        evas_gl_common_error_set(EVAS_GL_BAD_CONTEXT);
         return 0;
      }
 
@@ -2565,14 +2565,14 @@ evgl_make_current(void *eng_data, EVGL_Surface *sfc, 
EVGL_Context *ctx)
         if (!evgl_api_get(eng_data, ctx->version, EINA_FALSE))
           {
              ERR("Unable to get the list of GL APIs for version %d", 
ctx->version);
-             evas_gl_common_error_set(eng_data, EVAS_GL_NOT_INITIALIZED);
+             evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
              return 0;
           }
 
         if (!_context_ext_check(ctx))
           {
              ERR("Unable to check required extension for the current context");
-             evas_gl_common_error_set(eng_data, EVAS_GL_NOT_INITIALIZED);
+             evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
              return 0;
           }
      }
@@ -2592,7 +2592,7 @@ evgl_make_current(void *eng_data, EVGL_Surface *sfc, 
EVGL_Context *ctx)
         if (!sfc->color_buf && !_surface_buffers_create(sfc))
           {
              ERR("Unable to create specified surfaces.");
-             evas_gl_common_error_set(eng_data, EVAS_GL_BAD_ALLOC);
+             evas_gl_common_error_set(EVAS_GL_BAD_ALLOC);
              return 0;
           }
 
@@ -2610,7 +2610,7 @@ evgl_make_current(void *eng_data, EVGL_Surface *sfc, 
EVGL_Context *ctx)
                        if (!_surface_buffers_allocate(eng_data, sfc, 0, 0, 
ctx->version))
                          {
                             ERR("Unable to destroy surface buffers!");
-                            evas_gl_common_error_set(eng_data, 
EVAS_GL_BAD_ALLOC);
+                            evas_gl_common_error_set(EVAS_GL_BAD_ALLOC);
                             return 0;
                          }
                        sfc->buffers_allocated = 0;
@@ -2631,7 +2631,7 @@ evgl_make_current(void *eng_data, EVGL_Surface *sfc, 
EVGL_Context *ctx)
                             if (!_surface_buffers_allocate(eng_data, sfc, 
sfc->w, sfc->h, ctx->version))
                               {
                                  ERR("Unable Create Specificed Surfaces.  
Unsupported format!");
-                                 evas_gl_common_error_set(eng_data, 
EVAS_GL_BAD_ALLOC);
+                                 evas_gl_common_error_set(EVAS_GL_BAD_ALLOC);
                                  return 0;
                               }
                             sfc->buffers_allocated = 1;
@@ -2646,7 +2646,7 @@ evgl_make_current(void *eng_data, EVGL_Surface *sfc, 
EVGL_Context *ctx)
                   if (!_surface_buffers_allocate(eng_data, sfc, sfc->w, 
sfc->h, ctx->version))
                     {
                        ERR("Unable Create Allocate Memory for Surface.");
-                       evas_gl_common_error_set(eng_data, EVAS_GL_BAD_ALLOC);
+                       evas_gl_common_error_set(EVAS_GL_BAD_ALLOC);
                        return 0;
                     }
                   sfc->buffers_allocated = 1;
@@ -2829,7 +2829,7 @@ evgl_make_current(void *eng_data, EVGL_Surface *sfc, 
EVGL_Context *ctx)
                        if (!_surface_buffers_fbo_set(sfc, ctx->surface_fbo, 
ctx->version))
                          {
                             ERR("Attaching buffers to context fbo failed. 
Engine: %p  Surface: %p Context FBO: %u", evgl_engine, sfc, ctx->surface_fbo);
-                            evas_gl_common_error_set(eng_data, 
EVAS_GL_BAD_CONTEXT);
+                            evas_gl_common_error_set(EVAS_GL_BAD_CONTEXT);
                             return 0;
                          }
                     }
diff --git a/src/modules/evas/engines/gl_generic/evas_engine.c 
b/src/modules/evas/engines/gl_generic/evas_engine.c
index a3e19909f4..67b589064e 100644
--- a/src/modules/evas/engines/gl_generic/evas_engine.c
+++ b/src/modules/evas/engines/gl_generic/evas_engine.c
@@ -1853,7 +1853,7 @@ eng_gl_surface_query(void *engine, void *surface, int 
attr, void *value)
              */
            default: break;
           }
-        evas_gl_common_error_set(engine, EVAS_GL_BAD_ATTRIBUTE);
+        evas_gl_common_error_set(EVAS_GL_BAD_ATTRIBUTE);
         return EINA_FALSE;
      }
 #else
diff --git a/src/modules/evas/engines/gl_x11/evas_engine.c 
b/src/modules/evas/engines/gl_x11/evas_engine.c
index 45675ecaf0..46e47bb2b6 100644
--- a/src/modules/evas/engines/gl_x11/evas_engine.c
+++ b/src/modules/evas/engines/gl_x11/evas_engine.c
@@ -228,7 +228,7 @@ evgl_eng_make_current(void *data, void *surface, void 
*context, int flush)
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return 0;
      }
 
@@ -283,7 +283,7 @@ evgl_eng_make_current(void *data, void *surface, void 
*context, int flush)
         if (!ret)
           {
              ERR("glXMakeContextCurrent() failed!");
-             glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_DISPLAY);
+             glsym_evas_gl_common_error_set(EVAS_GL_BAD_DISPLAY);
              return 0;
           }
         return 1;
@@ -308,7 +308,7 @@ evgl_eng_make_current(void *data, void *surface, void 
*context, int flush)
           {
              ERR("glXMakeContextCurrent() failed. Ret: %d! Context: %p 
Surface: %p",
                  ret, (void *)ctx, (void *)sfc);
-             glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_DISPLAY);
+             glsym_evas_gl_common_error_set(EVAS_GL_BAD_DISPLAY);
              return 0;
           }
      }
@@ -327,7 +327,7 @@ evgl_eng_native_window_create(void *data)
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return NULL;
      }
 
@@ -356,7 +356,7 @@ evgl_eng_native_window_create(void *data)
    if (!win)
      {
         ERR("Creating native X window failed.");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_DISPLAY);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_DISPLAY);
         return NULL;
      }
 
@@ -372,14 +372,14 @@ evgl_eng_native_window_destroy(void *data, void 
*native_window)
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return 0;
      }
 
    if (!native_window)
      {
         ERR("Inavlid native surface.");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_NATIVE_WINDOW);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_NATIVE_WINDOW);
         return 0;
      }
 
@@ -402,7 +402,7 @@ evgl_eng_window_surface_create(void *data, void 
*native_window EINA_UNUSED)
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return NULL;
      }
 
@@ -444,7 +444,7 @@ evgl_eng_window_surface_destroy(void *data, void *surface)
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return 0;
      }
 
@@ -452,7 +452,7 @@ evgl_eng_window_surface_destroy(void *data, void *surface)
    if (!surface)
      {
         ERR("Invalid surface.");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_SURFACE);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_SURFACE);
         return 0;
      }
 
@@ -472,14 +472,14 @@ evgl_eng_context_create(void *data, void *share_ctx, 
Evas_GL_Context_Version ver
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return NULL;
      }
 
    if ((version < EVAS_GL_GLES_1_X) || (version > EVAS_GL_GLES_3_X))
      {
         ERR("Invalid context version number %d", version);
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_PARAMETER);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_PARAMETER);
         return NULL;
      }
 
@@ -488,7 +488,7 @@ evgl_eng_context_create(void *data, void *share_ctx, 
Evas_GL_Context_Version ver
        ((!eng_get_ob(re)->gl_context) || 
(eng_get_ob(re)->gl_context->gles_version != EVAS_GL_GLES_3_X)))
      {
         ERR("GLES 3 version not supported!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_ATTRIBUTE);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_ATTRIBUTE);
         return NULL;
      }
    EGLContext context = EGL_NO_CONTEXT;
@@ -537,7 +537,7 @@ evgl_eng_context_create(void *data, void *share_ctx, 
Evas_GL_Context_Version ver
      {
         int err = eglGetError();
         ERR("Engine Context Creations Failed. Error: %#x.", err);
-        glsym_evas_gl_common_error_set(data, err - EGL_SUCCESS);
+        glsym_evas_gl_common_error_set(err - EGL_SUCCESS);
         return NULL;
      }
 
@@ -564,8 +564,8 @@ evgl_eng_context_create(void *data, void *share_ctx, 
Evas_GL_Context_Version ver
    if (!context)
      {
         ERR("Internal Resource Context Creations Failed.");
-        if(!(eng_get_ob(re)->info->info.display)) 
glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_DISPLAY);
-        if(!(eng_get_ob(re)->win)) glsym_evas_gl_common_error_set(data, 
EVAS_GL_BAD_NATIVE_WINDOW);
+        if(!(eng_get_ob(re)->info->info.display)) 
glsym_evas_gl_common_error_set(EVAS_GL_BAD_DISPLAY);
+        if(!(eng_get_ob(re)->win)) 
glsym_evas_gl_common_error_set(EVAS_GL_BAD_NATIVE_WINDOW);
         return NULL;
      }
 
@@ -583,8 +583,8 @@ evgl_eng_context_destroy(void *data, void *context)
    if ((!re) || (!context))
      {
         ERR("Invalid Render Input Data. Engine: %p, Context: %p", data, 
context);
-        if (!re) glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
-        if (!context) glsym_evas_gl_common_error_set(data, 
EVAS_GL_BAD_CONTEXT);
+        if (!re) glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
+        if (!context) glsym_evas_gl_common_error_set(EVAS_GL_BAD_CONTEXT);
         return 0;
      }
 
@@ -606,7 +606,7 @@ evgl_eng_string_get(void *data)
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return NULL;
      }
 
@@ -639,7 +639,7 @@ evgl_eng_rotation_angle_get(void *data)
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return 0;
      }
 
@@ -648,7 +648,7 @@ evgl_eng_rotation_angle_get(void *data)
    else
      {
         ERR("Unable to retrieve rotation angle.");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_CONTEXT);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_CONTEXT);
         return 0;
      }
 }
@@ -739,7 +739,7 @@ evgl_eng_pbuffer_surface_create(void *data, EVGL_Surface 
*sfc,
        || (num_config < 1))
      {
         int err = eglGetError();
-        glsym_evas_gl_common_error_set(data, err - EGL_SUCCESS);
+        glsym_evas_gl_common_error_set(err - EGL_SUCCESS);
         ERR("eglChooseConfig failed with error %x", err);
         return NULL;
      }
@@ -770,7 +770,7 @@ evgl_eng_pbuffer_surface_create(void *data, EVGL_Surface 
*sfc,
    if (!egl_sfc)
      {
         int err = eglGetError();
-        glsym_evas_gl_common_error_set(data, err - EGL_SUCCESS);
+        glsym_evas_gl_common_error_set(err - EGL_SUCCESS);
         ERR("eglCreatePbufferSurface failed with error %x", err);
         return NULL;
      }
@@ -867,14 +867,14 @@ evgl_eng_pbuffer_surface_destroy(void *data, void 
*surface)
    if (!data)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(NULL, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return 0;
      }
 
    if (!surface)
      {
         ERR("Invalid surface.");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_SURFACE);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_SURFACE);
         return 0;
      }
 
@@ -912,14 +912,14 @@ evgl_eng_indirect_surface_create(EVGL_Engine *evgl 
EINA_UNUSED, void *data,
 
    if (!re || !evgl_sfc || !cfg)
      {
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_PARAMETER);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_PARAMETER);
         return NULL;
      }
 
    if ((w < 1) || (h < 1))
      {
         ERR("Inconsistent parameters, not creating any surface!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_PARAMETER);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_PARAMETER);
         return NULL;
      }
 
@@ -940,7 +940,7 @@ evgl_eng_indirect_surface_create(EVGL_Engine *evgl 
EINA_UNUSED, void *data,
    if (!px)
      {
         ERR("Failed to create XPixmap!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_ALLOC);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_ALLOC);
         return NULL;
      }
 
@@ -1023,7 +1023,7 @@ try_again:
      {
         int err = eglGetError();
         ERR("eglChooseConfig() can't find any configs, error: %x", err);
-        glsym_evas_gl_common_error_set(data, err - EGL_SUCCESS);
+        glsym_evas_gl_common_error_set(err - EGL_SUCCESS);
         XFreePixmap(eng_get_ob(re)->disp, px);
         return NULL;
      }
@@ -1103,7 +1103,7 @@ try_again:
      {
         int err = eglGetError();
         ERR("eglCreatePixmapSurface failed with error: %x", err);
-        glsym_evas_gl_common_error_set(data, err - EGL_SUCCESS);
+        glsym_evas_gl_common_error_set(err - EGL_SUCCESS);
         XFreePixmap(eng_get_ob(re)->disp, px);
         return NULL;
      }
@@ -1144,7 +1144,7 @@ evgl_eng_indirect_surface_destroy(void *data, 
EVGL_Surface *evgl_sfc)
    if (!re)
      {
         ERR("Invalid Render Engine Data!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_NOT_INITIALIZED);
+        glsym_evas_gl_common_error_set(EVAS_GL_NOT_INITIALIZED);
         return 0;
      }
 
@@ -1152,7 +1152,7 @@ evgl_eng_indirect_surface_destroy(void *data, 
EVGL_Surface *evgl_sfc)
    if ((!evgl_sfc) || (!evgl_sfc->indirect_sfc))
      {
         ERR("Invalid surface");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_SURFACE);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_SURFACE);
         return 0;
      }
 
@@ -1162,7 +1162,7 @@ evgl_eng_indirect_surface_destroy(void *data, 
EVGL_Surface *evgl_sfc)
    if (!evgl_sfc->indirect_sfc_native)
      {
         ERR("Inconsistent parameters, not freeing XPixmap for indirect 
surface!");
-        glsym_evas_gl_common_error_set(data, EVAS_GL_BAD_PARAMETER);
+        glsym_evas_gl_common_error_set(EVAS_GL_BAD_PARAMETER);
         return 0;
      }
 
@@ -1208,7 +1208,7 @@ evgl_eng_gles_context_create(void *data,
      {
         int err = eglGetError();
         ERR("eglCreateContext failed with error 0x%x", err);
-        glsym_evas_gl_common_error_set(data, err - EGL_SUCCESS);
+        glsym_evas_gl_common_error_set(err - EGL_SUCCESS);
         return NULL;
      }
 
@@ -1900,7 +1900,7 @@ eng_gl_error_get(void *engine)
 #endif
 
 end:
-   glsym_evas_gl_common_error_set(engine, EVAS_GL_SUCCESS);
+   glsym_evas_gl_common_error_set(EVAS_GL_SUCCESS);
    return err;
 }
 

-- 


Reply via email to