summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Kolesa <d.kolesa@samsung.com>2018-11-12 15:23:58 +0100
committerDaniel Kolesa <d.kolesa@samsung.com>2018-11-12 15:26:01 +0100
commitac46540e93a0a46ba962b3d6ce2a830bde3043f8 (patch)
tree048bb9a9761b4e212be5df1d28e9974a6a332cce
parentf92bf3d8cdf4aa9c00c225ecb7c155516b5de91e (diff)
eolian: use 'free' for owned mstring but not stringdevs/q66/eolian_mstring_freefunc
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
-rw-r--r--src/lib/eolian/database_validate.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/eolian/database_validate.c b/src/lib/eolian/database_validate.c
index 8858818dff..4217ba9431 100644
--- a/src/lib/eolian/database_validate.c
+++ b/src/lib/eolian/database_validate.c
@@ -261,7 +261,7 @@ _validate_type(Validate_State *vals, Eolian_Type *tp)
261 if (!tp->freefunc) 261 if (!tp->freefunc)
262 switch (id) 262 switch (id)
263 { 263 {
264 case KW_string: 264 case KW_mstring:
265 tp->freefunc = eina_stringshare_add(eo_str_free); 265 tp->freefunc = eina_stringshare_add(eo_str_free);
266 break; 266 break;
267 case KW_stringshare: 267 case KW_stringshare: