This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [gdbserver, doc] add command line option to force core dump on fatal errors
- From: Jan Kratochvil <jan dot kratochvil at redhat dot com>
- To: Pedro Alves <pedro at codesourcery dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Thu, 15 Sep 2011 08:30:20 +0200
- Subject: Re: [gdbserver, doc] add command line option to force core dump on fatal errors
- References: <201109141639.07804.pedro@codesourcery.com>
On Wed, 14 Sep 2011 17:39:07 +0200, Pedro Alves wrote:
> gdbserver does `exit(1)' on fatal errors, instead of aborting,
> because we don't normally want embedded/deployed targets to end
> up filled with core files if gdbserver happens to trip on some bug.
>
> However, when running the testsuite (and other situations) against
> gdbserver, it's quite useful to have it dump core.
I would make it more simple to abort always, there is already `ulimit -c' to
control whether one wants a core file or not.
> (yes, I know we should try to increase the core soft limit like
> gdb does before calling abort. I'm leaving that to a follow
> up, possibly moving dump_core to common/).
The soft limit bump could be rather controlled by `--internal-error-corefile'.
gdbserver is different from gdb in that it is not interactive.
Thanks,
Jan