James Skidmore
James Skidmore

Reputation: 50278

How to determine where this memory leak is coming from?

How can I determine where this memory leak is coming from in my code? It doesn't reference anything but the "main" function in my application.

leak image

Upvotes: 2

Views: 581

Answers (2)

bbum
bbum

Reputation: 162712

As Joey said; you can't use Zombie Detection and Leak Detection at the same time.

You have Zombie Detection enabled in the Object Alloc instrument.

Turn off zombie detection and Leaks will work again.

The Leaks instrument really should detect this situation, thus I filed <rdar://problem/7139389> and have included a link to this article in the bug report.

Upvotes: 1

Joey Hagedorn
Joey Hagedorn

Reputation: 2408

It looks like you're trying to use NSZombieEnabled and leaks at the same time. These two diagnostic techniques don't work together--NSZombieEnabled makes all deallocated objects just stick around, so they will appear as leaks.

Simply turn off NSZombieEnabled and you should be set for this case.

Upvotes: 7

Related Questions