add a crash handler at initialization

`[crash]` is mean to be a log section, so it should be small. This is in fact used for when the program crashes: it only catches exceptions on the main thread.