discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=217551e92be2813fc8f847686bfaa7751b545ddb

commit 217551e92be2813fc8f847686bfaa7751b545ddb
Author: Mike Blumenkrantz <zm...@osg.samsung.com>
Date:   Thu May 5 10:38:31 2016 -0400

    wayland_egl: ensure gl context destruction when unsetting wl_display
    
    extra refcounting during setup in this case will prevent the context
    destruction, leading to a dead gl context which is unable to render
---
 src/modules/evas/engines/wayland_egl/evas_engine.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/src/modules/evas/engines/wayland_egl/evas_engine.c 
b/src/modules/evas/engines/wayland_egl/evas_engine.c
index 4945a70..1252e91 100644
--- a/src/modules/evas/engines/wayland_egl/evas_engine.c
+++ b/src/modules/evas/engines/wayland_egl/evas_engine.c
@@ -726,8 +726,14 @@ eng_setup(Evas *evas, void *info)
                  (ob->info->info.screen != ob->screen) ||
                  (ob->info->info.destination_alpha != ob->alpha))
                {
-                  ob->gl_context->references++;
                   gl_wins--;
+                  if (!ob->info->info.display)
+                    {
+                       eng_window_free(re->generic.software.ob);
+                       re->generic.software.ob = NULL;
+                       epd->engine.data.output = NULL;
+                       goto ob_err;
+                    }
 
                   ob = eng_window_new(evas, inf, epd->output.w, epd->output.h, 
swap_mode);
                   if (!ob) goto ob_err;
@@ -737,7 +743,6 @@ eng_setup(Evas *evas, void *info)
                   
evas_render_engine_software_generic_update(&re->generic.software, ob,
                                                              epd->output.w, 
epd->output.h);
                   gl_wins++;
-                  eng_get_ob(re)->gl_context->references--;
                }
              else if ((ob->w != epd->output.w) || (ob->h != epd->output.h) ||
                       (ob->info->info.rotation != ob->rot))

-- 


Reply via email to