elm widget - fix weak reference messup that causes segv's

welm widget weak refered the logical parent slot but never unreffed
the weak ref - ever. this should fix that. in fact it does. one crash
less with:

elementary_test -to "icon standard"

@fix
This commit is contained in:
Carsten Haitzler 2017-04-21 15:58:04 +09:00
parent 9d5a1d098c
commit a6253f44a9
1 changed files with 7 additions and 0 deletions

View File

@ -352,6 +352,8 @@ _logical_parent_eval(Eo *obj EINA_UNUSED, Elm_Widget_Smart_Data *pd)
}
logical_wd->logical.child_count --;
old = pd->logical.parent;
if (pd->logical.parent)
efl_weak_unref(&pd->logical.parent);
pd->logical.parent = NULL;
}
if (parent)
@ -6203,6 +6205,11 @@ _elm_widget_efl_object_destructor(Eo *obj, Elm_Widget_Smart_Data *sd EINA_UNUSED
sd->manager.provider = NULL;
elm_interface_atspi_accessible_removed(obj);
if (sd->logical.parent)
{
efl_weak_unref(&sd->logical.parent);
sd->logical.parent = NULL;
}
}
EOLIAN static Eina_Bool