1

I am just curious. VB.net and visual studio allows that right. Does xcode allows that too? Kind of a cool feature you know.

user4951
  • 32,206
  • 53
  • 172
  • 282
  • What IS it? It sounds like something XCode does, but please describe it. – crimson_penguin May 05 '11 at 06:38
  • Just-in-time-debugging is a feature of Visual Studio that allows the user to automatically attach the debugger to any program that crashed, even if the IDE wasn’t running before. – Sven May 05 '11 at 06:42

2 Answers2

1

No, Xcode or Mac OS X doesn’t have that feature.

Sven
  • 22,475
  • 4
  • 52
  • 71
1

No, however you can enable core dumps. This allows you to use the debugger to inspect the memory of a process after it crashes, although the program will no longer be running.

See: How to enable full coredumps on OS X?

If you have a program that crashes, you can put a wrapper script around it that enables core dumps for that application only. You can even distribute the modified application to users and get core dumps from them. The wrapper script would look like this:

$ cd MyCoolApp.app/Contents/MacOS
$ ls
MyCoolApp
$ mv MyCoolApp MyCoolApp.real
$ cat > MyCoolApp <<EOF
> #!/bin/sh
> ulimit -c unlimited
> exec MyCoolApp.real
> EOF
$ chmod +x MyCoolApp
Community
  • 1
  • 1
Dietrich Epp
  • 205,541
  • 37
  • 345
  • 415