0

I am getting a crash in my application which I am not able to trace out. In the log I am getting :

[CFString release]: message sent to deallocated instance 0xeb8a560

Even on debugging I could not trace out the crash. I placed breakpoints and enabled NSZombie but still not helpful. Does anyone have some idea for getting the location of crash?

halfer
  • 19,824
  • 17
  • 99
  • 186
Nitish
  • 13,845
  • 28
  • 135
  • 263
  • Set MallocStackLogging, MallocStackLoggingNoCompact environments - https://developer.apple.com/library/mac/#documentation/Performance/Conceptual/ManagingMemory/Articles/MallocDebug.html – rishi May 16 '12 at 05:58

3 Answers3

2

for getting the exact location of crash, you need to add 'Exception BreakPoint' , that will add breakpoint to exact location where the crash occurs.

In the left side column of xcode 4:

  1. tap on the breakpoint tab (the 6th tab over)
  2. tap on the + button in the bottom left of the window
  3. tap 'add exception breakpoint'
  4. tap 'done' on the popup

reference "Run > Stop on Objective-C exception" in Xcode 4?

Community
  • 1
  • 1
waheeda
  • 1,097
  • 1
  • 9
  • 18
1

A string object over released. You can create an exception break point to find where it crashes. Also you can try using bt in GDB to get crash log.

This link lots of tricks and tips.

Vignesh
  • 10,205
  • 2
  • 35
  • 73
0

This type of error (using class retain/release memory management) can also be debugged using the Zombies Instrument. Often (not always) you can see the history of where the deallocated object was retained/released and figure out why is vanished out from under you.

ahwulf
  • 2,584
  • 15
  • 29