raster pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=82c6bdf031eb50ef444a95ca7fe48a8146ccce43

commit 82c6bdf031eb50ef444a95ca7fe48a8146ccce43
Author: Carsten Haitzler (Rasterman) <ras...@rasterman.com>
Date:   Wed Aug 3 17:27:23 2016 +0900

    e comp - set alpha after setting native surface to avoid random crash
    
    i noticed a crash on texture update with a previous garbage image data
    ptr set before becoming a native suttface and so setting alpha would
    cause a texture upload from a garbage pointer, so set native surface
    then set alpha on or off so the data ptr is no longer used.
    
    @fix
---
 src/bin/e_comp_object.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c
index af97018..32b4756 100644
--- a/src/bin/e_comp_object.c
+++ b/src/bin/e_comp_object.c
@@ -3751,8 +3751,8 @@ e_comp_object_native_surface_set(Evas_Object *obj, 
Eina_Bool set)
    evas_object_image_native_surface_set(cw->obj, set && (!cw->blanked) ? 
(cw->ns ?: &ns) : NULL);
    EINA_LIST_FOREACH(cw->obj_mirror, l, o)
      {
-        evas_object_image_alpha_set(o, !!cw->ns ? 1 : cw->ec->argb);
         evas_object_image_native_surface_set(o, set ? (cw->ns ?: &ns) : NULL);
+        evas_object_image_alpha_set(o, !!cw->ns ? 1 : cw->ec->argb);
      }
 }
 

-- 


Reply via email to