Skip to content
This repository has been archived by the owner on Sep 16, 2021. It is now read-only.

possible memory leak on function dlr_device_construct, libdleyna/renderer/device.c #165

Open
vpereira opened this issue May 8, 2018 · 6 comments

Comments

@vpereira
Copy link

vpereira commented May 8, 2018

Hi, I was wondering if we wouldn't have a memory leak because we aren't freeing priv_t which could lead to denial of service (crash) as soon g_new0 fails (AFAIK g_new0 aborts when it fails)

code for reference:

priv_t = g_new0(prv_new_device_ct_t, 1);

@phako
Copy link

phako commented Nov 5, 2018

If you look at https://github.com/intel/dleyna-renderer/blob/139129086cd48879d5aeb992a841ea220cc65fd2/libdleyna/renderer/device.c#L823` the priv_t is passed as user_data to the task together with a free_func g_free. The task takes over ownership of priv_t and frees it when its done

@rbjorklin
Copy link

Probably not related to this particular function but on my machine with 16G RAM I've seen the dleyna-renderer process consume ~30% of system memory with only tmux, gedit and thunderbird running at the time. I'm guessing ~5GB of RAM use is not expected?

@phako
Copy link

phako commented Jul 29, 2019

it does some mmap for some use-cases. the numbers might be deceiving

@zlynx
Copy link

zlynx commented Sep 18, 2019

I had to kill -9 dleyna-renderer just now because it was using 8.5 GB actual RSS. Nothing about virtual mmap going on there.

@phako
Copy link

phako commented Sep 18, 2019

Were you using it at all or was it merely idling in the background?

@zlynx
Copy link

zlynx commented Sep 18, 2019 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants