[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-bugs-dist
Subject:    [Bug 237239] Kmix memory leak
From:       Colin Guthrie <cguthrie () mandriva ! org>
Date:       2011-03-30 23:04:23
Message-ID: 20110330230423.1A6CE84252 () immanuel ! kde ! org
[Download RAW message or body]

https://bugs.kde.org/show_bug.cgi?id=237239





--- Comment #27 from Colin Guthrie <cguthrie mandriva org>  2011-03-31 01:04:19 ---
OK, so having a quick look, I thought there might be a leak of _showPanelBox in
ViewDockAreaPopup::add(). But in retrospect, it's actually cleared out in
ViewDockAreaPopup::_setMixSet(), it's just confusing that it's got it's own
variable. I've refactored this, but it's not the issue.

I looked a bit further and I think there is a leak of a KMenu every time the
context menu is shown.

Fixed here:
http://colin.guthr.ie/git/kdemultimedia-trunk/commit/?id=04b7595794b9e282bb24fc42a7be6a79a85af03c

I suspect it's not the only leak but it's one I happened to notice.

There could be leaks in the PA stuff specifically, but the only things I
actually allocate memory for are m_mixDevices. It could be worth putting in a
debug statement somewhere that prints the count of m_mixDevices every now and
then and then so you can see if it's growing... If it does that would indicate
where the leak could occur. I'm not sure how this could happen but looking at
the code, I guess it is possible.

The only other thing that will be allocated in a general case with PA is the
pa_operation*'s but I've looked and AFAICT these are all unreffed properly.

I think it would have taken a lot to generate 300Megs worth of leaked KMenus,
so while it may help, I doubt this is the end of the tale...

-- 
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are watching all bug changes.
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic