Edje: invalidate double named group

What happens if a group has 2 name statements("double named")?
edje will fail to free the groups cache while shuting down due
the collection directory entry hash having two entries with
different names but pointing to the same object - the second try
to free the part mem pool will fail - since it was freed before -
and issue an abort.


SVN revision: 82093
This commit is contained in:
Leandro Dorileo 2013-01-03 18:17:42 +00:00
parent 0a2d116119
commit c403be3bb7
1 changed files with 7 additions and 0 deletions

View File

@ -2464,6 +2464,9 @@ st_collections_group_name(void)
current_pc = eina_list_data_get(eina_list_last(edje_collections));
if (current_de->entry)
goto double_named_group;
current_de->entry = parse_str(0);
current_pc->part = current_de->entry;
@ -2486,6 +2489,10 @@ st_collections_group_name(void)
break;
}
double_named_group:
ERR("Invalid group, only a single name statement is valid for group, use "
"alias instead.");
exit(-1);
}
typedef struct _Edje_List_Foreach_Data Edje_List_Foreach_Data;