From ffcc5e72d90b35e13d9ce9492fbba53cf849a638 Mon Sep 17 00:00:00 2001 From: Gwanglim Lee Date: Fri, 18 Apr 2014 12:51:36 -0400 Subject: [PATCH] null check ecstack Summary: fix segmentation fault error Test Plan: run enlightenment (wl only server) -> run elementary_test -> run terminlogy -> move cursor to elementary_test -> click on elementary_test Reviewers: raster, devilhorns, zmike CC: cedric Differential Revision: https://phab.enlightenment.org/D770 --- src/bin/e_comp_object.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c index 3f590bc10..c4e063b5e 100644 --- a/src/bin/e_comp_object.c +++ b/src/bin/e_comp_object.c @@ -1078,7 +1078,7 @@ _e_comp_intercept_stack_helper(E_Comp_Object *cw, Evas_Object *stack, E_Comp_Obj else _e_comp_object_layers_add(cw, NULL, NULL, 0); /* set restack if stacking has changed */ - if (cw->ec->new_client || (ecstack->frame != o)) + if (cw->ec->new_client || (!ecstack) || (ecstack->frame != o)) evas_object_data_set(cw->smart_obj, "client_restack", (void*)1); stack_cb(cw->smart_obj, stack); if (cw->comp->layers[cw->layer].obj) @@ -1086,7 +1086,7 @@ _e_comp_intercept_stack_helper(E_Comp_Object *cw, Evas_Object *stack, E_Comp_Obj { CRI("STACKING ERROR!!!"); } - if (cw->ec->new_client || (ecstack->frame != o)) + if (cw->ec->new_client || (!ecstack) || (ecstack->frame != o)) evas_object_data_del(cw->smart_obj, "client_restack"); e_comp_shape_queue(cw->comp); }