summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSung W. Park <dunamis.park@samsung.com>2013-11-13 15:39:12 +0900
committerSung W. Park <dunamis.park@samsung.com>2013-11-13 15:39:12 +0900
commit90bbc21d02b9cdc7e074884812950d27e015c2ac (patch)
tree9d054cd04f3f14e91e9dadcf6218ae6c1eaf26fe /src
parent2dc092d36e0741bcdffca23f82b2acbac8e0cda7 (diff)
evas_gl : Fixed macro substitution bug in evas_gl
In evas_gl_api_ext_def.h there're calls such as: _EVASGL_EXT_DRVNAME(EGL_KHR_image_base) The macro is defined in evas_gl_api_ext.c as: (strstr(glexts, #name) != NULL || strstr(glueexts, #name) != NULL) if (_EVASGL_EXT_CHECK_SUPPORT(name)) *ext_support = 1; But EGL_KHR_image_base is itself a macro, which is defined in EGL/eglext.h like this: Thus, the _EVASGL_EXT_CHECK_SUPPORT macro will unwrap into: (strstr(glexts, "1") != NULL || strstr(glueexts, "1") != NULL) instead of intended: (strstr(glexts, "EGL_KHR_image_base") != NULL || strstr(glueexts, "EGL_KHR_image_base") != NULL) This patch fixes this by applying stringification earlier in _EVASGL_EXT_DRVNAME Bugfix reported by jinhyung.jo@samsung.com
Diffstat (limited to 'src')
-rw-r--r--src/modules/evas/engines/gl_common/evas_gl_api_ext.c4
1 files changed, 2 insertions, 2 deletions
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 dcf5f1c8be..0573c6d178 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
@@ -184,13 +184,13 @@ re->info->info.screen);
184 } 184 }
185 185
186#define _EVASGL_EXT_CHECK_SUPPORT(name) \ 186#define _EVASGL_EXT_CHECK_SUPPORT(name) \
187 (strstr(glexts, #name) != NULL || strstr(glueexts, #name) != NULL) 187 (strstr(glexts, name) != NULL || strstr(glueexts, name) != NULL)
188 188
189#define _EVASGL_EXT_DISCARD_SUPPORT() \ 189#define _EVASGL_EXT_DISCARD_SUPPORT() \
190 *ext_support = 0; 190 *ext_support = 0;
191 191
192#define _EVASGL_EXT_DRVNAME(name) \ 192#define _EVASGL_EXT_DRVNAME(name) \
193 if (_EVASGL_EXT_CHECK_SUPPORT(name)) *ext_support = 1; 193 if (_EVASGL_EXT_CHECK_SUPPORT(#name)) *ext_support = 1;
194 194
195#define _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param) \ 195#define _EVASGL_EXT_FUNCTION_BEGIN(ret, name, param) \
196 { \ 196 { \