app: replace g_on_error_query() and g_on_error_stack_trace() by...
... our own implementation. Though the GUI stacktrace is better for most (because it is visible even when not run in a terminal), the CLI options are quite useful too and may still be preferred by some, in particular developers. So it may as well be benefiting from the better implementation. Glib traces are quite weak even though they also use gdb and debug info are present (often, even though I had these traces, I had to run gdb separately; now it won't be necessary in many cases). My traces include more information. Note that I didn't implement gimp_print_stack_trace() from previous gimp_get_stack_trace() because I cannot allocate a string after some types of crash (e.g. segmentation faults). So instead, gimp_print_stack_trace() now take care optionally of both cases: either allocating a string, or directly pipe to a file descriptor.
Showing with 163 additions and 57 deletions