Allow specifying a callback

Made it so that you can specify a callback and you get a stacktrace in it. You can then write to the file yourself if you want or do anything else (write to the database).
I do get the value of a JS callback - being able to report the segfault to a central logging service would be super cool.  I'm just paranoid and want a second copy written on the local filesystem incase everything goes sideways before the log line gets written out.  The issue I was debugging when I wrote this code originally only reproduced after a few days of production usage, so I needed to be certain I'd capture the stack the next time it happened, even if it required SSHing into the box that died.