Page MenuHomePhabricator

eo: Fix memory leak in efl_key_wref_set() api.

Authored by smohanty on May 27 2020, 12:39 AM.

Diff Detail

rEFL core/efl
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.
smohanty created this revision.May 27 2020, 12:39 AM

It seems that this patch has no reviewers specified. If you are unsure who can review your patch, please check this wiki page and see if anyone can be added:

smohanty requested review of this revision.May 27 2020, 12:40 AM

in _eo_key_generic_direct_del() we remove the node from the ext->generic_data . Because of call_free is false we never call _eo_generic_data_node_free() on the node hence the leak.

@raster ,
Could you please review this when you have time . I don't know if this is the correct fix but the memory leak shows up in address sanitizer.

@bu5hm4n Could you please review this?

I'll give it a look tomorrow :)

bu5hm4n accepted this revision.Jun 1 2020, 11:06 PM

Seems to look fine. Lets see if it breaks for someone else ... (Its also kind of weird that there is a free func where you can tell to *not* free the node)

This revision is now accepted and ready to land.Jun 1 2020, 11:06 PM
Closed by commit rEFL579712933478: eo: Fix memory leak in efl_key_wref_set() api. (authored by smohanty, committed by Marcel Hollerbach <>). · Explain WhyJun 1 2020, 11:08 PM
This revision was automatically updated to reflect the committed changes.