Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Posts: 206
Registered: ‎05-15-2012
My Device: None
My Carrier: Telus

WebView Memory Leak / Cache Settings



I have a page that makes use of a WebView, that I push onto a NavigationPane.


When I watch my System Memory in the "System Summary" QNX System Information Perspective, my free memory drops from about 300M to 100M when I open the page. Fair enough, it's a large page, it is a photoalbum with high-res photos. Now, when I pop that page, then delete it, from the navigation stack, the system memory that is free goes back up to about about 170M. So I've effectively just lost half my memory. By opening that same WebView inside the Page I push over and over, I can eventually crash my app. The memory loss is not nearly as significant in subsequent runs, but there is still always a net memory loss. I've attempted to clear the WebStorage after the WebView is finished loading with this code:



 as far as I can tell this has no effect at all on my app's memory usage.


Anyone have any ideas what might be going on here?


Check out my app, Alien Flow for reddit

And of course, like my post if you found it helpful or informative!
Posts: 135
Registered: ‎04-25-2009
My Device: Z30
My Carrier: AT&T

Re: WebView Memory Leak / Cache Settings

Did you ever find a fix for this? I have the same issue, thanks!