From: sung Date: Mon, 30 Jan 2012 11:21:38 +0000 (+0000) Subject: Fixing my silly mistake before someone else catches it. X-Git-Tag: 2.0_alpha~149^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=2b8da18afcfed0c5ae2df49e6a060d3b62d196a8;p=framework%2Fuifw%2Fevas.git Fixing my silly mistake before someone else catches it. I was accessing a variable before it was NULL checked. Fixed now. git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/evas@67601 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/modules/engines/gl_x11/evas_engine.c b/src/modules/engines/gl_x11/evas_engine.c index 589b242..5edbb19 100644 --- a/src/modules/engines/gl_x11/evas_engine.c +++ b/src/modules/engines/gl_x11/evas_engine.c @@ -3286,16 +3286,6 @@ eng_gl_make_current(void *data __UNUSED__, void *surface, void *context) sfc = (Render_Engine_GL_Surface*)surface; ctx = (Render_Engine_GL_Context*)context; - // Check if direct rendering is possible: - // It's possible when direct_fb_opt is on and either current image - // object is valid or gl_direct_override is on. Override allows - // rendering outside of pixel getter but it doesn't guarantee - // correct rendering. - if ((sfc->direct_fb_opt) && (gl_direct_img_obj || gl_direct_override)) - gl_direct_enabled = 1; - else - gl_direct_enabled = 0; - // Unset surface/context if ((!sfc) || (!ctx)) { @@ -3317,6 +3307,16 @@ eng_gl_make_current(void *data __UNUSED__, void *surface, void *context) return 1; } + // Check if direct rendering is possible: + // It's possible when direct_fb_opt is on and either current image + // object is valid or gl_direct_override is on. Override allows + // rendering outside of pixel getter but it doesn't guarantee + // correct rendering. + if ((sfc->direct_fb_opt) && (gl_direct_img_obj || gl_direct_override)) + gl_direct_enabled = 1; + else + gl_direct_enabled = 0; + if (gl_direct_enabled) { // Do a make current only if it's not already current