From e6acf2379207c5ae7c3bcc017c26a02b14124401 Mon Sep 17 00:00:00 2001 From: Hermet Park Date: Tue, 16 Mar 2021 12:43:22 +0900 Subject: [PATCH] edje: add null check for safety. Change-Id: I083822860854a91fc3dcc2e2cdd9b26842b820ed --- src/lib/edje/edje_part.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/lib/edje/edje_part.c b/src/lib/edje/edje_part.c index cd1bf39..b687dd0 100644 --- a/src/lib/edje/edje_part.c +++ b/src/lib/edje/edje_part.c @@ -198,7 +198,11 @@ EOLIAN static void _efl_canvas_layout_part_efl_object_debug_name_override(Eo *obj, Efl_Canvas_Layout_Part_Data *pd, Eina_Strbuf *sb) { efl_debug_name_override(efl_super(obj, MY_CLASS), sb); - eina_strbuf_append_printf(sb, "%s : %s : %s", pd->part, _part_type_to_string(pd->rp->type), pd->ed->group); + + const char* type = pd->rp ? _part_type_to_string(pd->rp->type) : NULL; + const char* group = pd->ed ? pd->ed->group : NULL; + + eina_strbuf_append_printf(sb, "%s : %s : %s", pd->part, type, group); } #include "efl_canvas_layout_part_type_provider.eo.c" -- 2.7.4