Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Memory leak every time UIScrollView is released

In my app I have a scroll view and four table views. Each time one is dragged and then released, I get a 48 byte leak. This really adds up. As you can see, both groups of leaks have the same source. Has anyone seen a leak like this before?




Edit 1:

When I click on the arrow next to the leak, I get this information for the leak:

like image 893
eric.mitchell Avatar asked Mar 18 '12 22:03

eric.mitchell


People also ask

What is the main cause of memory leaks?

A memory leak starts when a program requests a chunk of memory from the operating system for itself and its data. As a program operates, it sometimes needs more memory and makes an additional request.

Is memory leak permanent?

Memory leaks don't result in physical or permanent damage. Since it's a software issue, it will slow down the applications or even your whole system. However, a program taking up a lot of RAM space doesn't always mean its memory is leaking somewhere. The program you're using may really need that much space.

Is memory leak serious?

Very dangerous. Memory leaks in the kernel level lead to serious system stability issues. Kernel memory is very limited compared to user land memory and should be handled cautiously.


1 Answers

What you are seeing is a known bug in iOS 5.1 and is being discussed in the iOS Developer Forums as such. You can find the relevant thread by searching in the forums for "strdup". See the thread titled "Elements App Memory Leak". Search for the post from an Apple employee.

like image 162
Cliff Ribaudo Avatar answered Sep 20 '22 15:09

Cliff Ribaudo