forked from enlightenment/efl
eolian: use 'free' for owned mstring but not string
Summary: Strings are const and if these are meant to be owned then it should define its own special free func. Mstrings are mutable and therefore can be owned and freed using standard free() by default. This fixes some warnings around the EFL caused by empty fallback free funcs created by the eolian generator, and these mutable strings were not being freed and potentially leaked. Reviewers: bu5hm4n, stefan_schmidt Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D7261
This commit is contained in:
parent
574e73598e
commit
04c4bb5834
|
@ -261,7 +261,7 @@ _validate_type(Validate_State *vals, Eolian_Type *tp)
|
|||
if (!tp->freefunc)
|
||||
switch (id)
|
||||
{
|
||||
case KW_string:
|
||||
case KW_mstring:
|
||||
tp->freefunc = eina_stringshare_add(eo_str_free);
|
||||
break;
|
||||
case KW_stringshare:
|
||||
|
|
Loading…
Reference in New Issue