edje_cc: Avoid segfault when strcmp NULL items

Martin reported a porblem with one of the SHR project edc files after an upgrade
to 1.13. The segfault itself is easy enough to fix here but I think there might
be other problems with the edc after this segfault is gone. We will see.

Fixes T2106
This commit is contained in:
Stefan Schmidt 2015-02-12 15:24:27 +01:00
parent 8ba1498361
commit 80d5f02276
1 changed files with 1 additions and 1 deletions

View File

@ -386,7 +386,7 @@ check_source_links(Edje_Part_Collection *pc, Edje_Part *ep, Eet_File *ef, Eina_L
EINA_LIST_FOREACH(edje_collections, l, pc_source) EINA_LIST_FOREACH(edje_collections, l, pc_source)
{ {
/* Find sourced group */ /* Find sourced group */
if (strcmp(ep->source, pc_source->part) == 0) if (ep->source && pc_source->part && strcmp(ep->source, pc_source->part) == 0)
{ {
/* Go through every part to find parts with type GROUP */ /* Go through every part to find parts with type GROUP */
for (i = 0; i < pc_source->parts_count; ++i) for (i = 0; i < pc_source->parts_count; ++i)