Tips for debugging EXC_BAD_ACCESS
Jacob Carlborg
doob at me.com
Fri Oct 12 05:40:35 PDT 2012
On 2012-10-11 20:19, Michel Fortin wrote:
> Most likely, the object objc_msgSend is called on has been deallocated,
> which would mean that windowSendEvent is called with a deallocated
> NSWindow object as its first argument.
I have done some investigation and I can call other methods on the
NSWindow object, but regular methods and super methods. This would
indicate that it's something wrong with the NSEvent object, but I can
call methods on that as well.
> Since you're on OS X, I'd suggest you try using Instruments to track the
> reference counters of all Objective-C objects within your program until
> it crashes, then search back the history for all
> retain/release/autorelease calls made to the address the EXEC_BAD_ACCESS
> happens on.
I don't know how to use Instruments for this.
--
/Jacob Carlborg
More information about the Digitalmars-d
mailing list