# midori/xombrero memory leaks?



## jozze (Apr 13, 2013)

I really don't know where to put this topic, but I think this is where it should be, since it might concern different ports.

Few weeks ago I made a clean install of FreeBSD 9.1 and I really tried to keep it lightweight (SLiM and dwm). I love the OS and how configurable it is, however, I think there may be a memory leak in one of the ports I installed.

Usually it starts like this:
I start a browser (I tried with xombrero, and midori) and open some tabs. After I close it, the active RAM value given by (h)top does not return to the pre-browser value, but some 10MB higher (depends on which webpages were in those tabs).

However, this cannot be normal: in some cases, while watching some specific videos on youtube, the RAM consumption grows over all limits, and I was forced to kill the browser.

I built my system with clang using ports only.

I don't know, how to begin solving my problem. Is this behaviour normal? If not, how do I find the source of the leak? Does it have to come from the browser? Or can it be a consequence of clang, dwm ...

Could you please give me some advice?


----------



## wblock@ (Apr 13, 2013)

FreeBSD does not unload file cache unless there is a need for it.  The FreeBSD saying is "memory that is not used is wasted".  This probably explains the first one.  The second is probably a bug, maybe in Flash.


----------



## jozze (Apr 13, 2013)

Aha, okay. Thanks for the explanation 

As for the second one: I've been trying to reproduce the result on firefox, using many tabs running different YouTube videos and I wasn't able to reproduce the result, and the mismatch in active RAM was only 2MB.

Maybe it's a browser thing. I'll post more if I manage to reproduce it in firefox.


----------



## jozze (Apr 14, 2013)

So far I wasn't able to reproduce the same results in neither firefox nor opera, which is one I am using now.

I guess this post can be tagged as solved.


----------



## Beastie (Apr 14, 2013)

Just an idea. Do you have the latest www/webkit-gtk2?

Perhaps you could try building Vimprobable which is also based on Webkit.


----------



## kpa (Apr 14, 2013)

Looking at the virtual memory statistics is not a good way to prove or disprove anything about memory leaks. You'll have to use something like devel/valgrind to get a proper picture whether memory is being leaked or not.


----------



## jozze (Apr 15, 2013)

Thank you guys!

@kpa: I'll look into it. Thanks. I thought (h)top was the most reliable way.
@Beastie: yeah, I do have the latest www/webkit-gtk2. I'll try building that vim thing.

I think now the problem was Skype x(. I had it open all those times and it happened now too, while listening to Vivaldi, http://www.youtube.com/watch?v=MPtPLCKe6w8, active RAM, used by Skype rose to < 300MB. I have been trying to convince my friends to use something different, but they like to stick to it 

Thanks again :beergrin


----------



## Beastie (Apr 15, 2013)

jozze said:
			
		

> while listening to Vivaldi,
> 
> http://www.youtube.com/watch?v=MPtPLCKe6w8


Great taste!


----------

