eolian - fix possible leak of name string

fixes CID 1232734
This commit is contained in:
Carsten Haitzler 2014-08-27 11:25:40 +09:00
parent d09262b011
commit 0c99a2f156
1 changed files with 4 additions and 1 deletions

View File

@ -105,7 +105,10 @@ _type_generate(const Eolian_Type *tp, Eina_Bool in_typedef, Eina_Bool full)
const Eolian_Enum_Type_Field *member;
char *name = _concat_name(tp);
if (!full)
break;
{
free(name);
break;
}
if (in_typedef)
{
eina_strbuf_append_printf(buf, "enum %s", name);