inwin, layout: Check null before calling eo_isa.

This commit is contained in:
Daniel Juyung Seo 2014-01-13 23:09:25 +09:00
parent b70db6eefb
commit f1457a3540
2 changed files with 2 additions and 2 deletions

View File

@ -118,7 +118,7 @@ _constructor(Eo *obj, void *_pd EINA_UNUSED, va_list *list EINA_UNUSED)
eo_do(obj, eo_parent_get(&parent));
if (!eo_isa(parent, ELM_OBJ_WIN_CLASS))
if (parent && !eo_isa(parent, ELM_OBJ_WIN_CLASS))
{
eo_error_set(obj); /* *has* to have a parent window */
return;

View File

@ -2209,7 +2209,7 @@ _dbg_info_get(Eo *eo_obj, void *_pd EINA_UNUSED, va_list *list)
eo_do_super(eo_obj, MY_CLASS, eo_dbg_info_get(root));
ELM_WIDGET_DATA_GET_OR_RETURN(eo_obj, wd);
if (eo_isa(wd->resize_obj, EDJE_OBJ_CLASS))
if (wd->resize_obj && eo_isa(wd->resize_obj, EDJE_OBJ_CLASS))
{
Eo_Dbg_Info *group = EO_DBG_INFO_LIST_APPEND(root, MY_CLASS_NAME);
const char *file, *edje_group;