views:

488

answers:

2

On Mac OS X, if I send SIGQUIT to my C program, it terminates, but there is no core dump file.

Do you have to manually enable core dumps on Mac OS X (how?), or are they written to somewhere else instead of the working directory?

+5  A: 

It seems they are suppressed by default. Running

$ ulimit -c unlimited

Will enable core dumps, and it will be placed in /cores/ as core.PID

frou
+3  A: 

by default, specific directories in mac osx are hidden. you might want to enable this feature in the terminal and then the core dump should be visible within the directory /cores.

defaults write com.apple.finder AppleShowAllFiles TRUE

Gnark
Thank you. I was browsing with Terminal (ls -lah), but that's a useful tip anyway.
frou