This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA] Fix gdb/15827 (crash w/corrupt DWARF)
- From: Doug Evans <dje at google dot com>
- To: Joel Brobecker <brobecker at adacore dot com>
- Cc: Keith Seitz <keiths at redhat dot com>, "gdb-patches at sourceware dot org ml" <gdb-patches at sourceware dot org>
- Date: Fri, 21 Mar 2014 12:27:28 -0700
- Subject: Re: [RFA] Fix gdb/15827 (crash w/corrupt DWARF)
- Authentication-results: sourceware.org; auth=none
- References: <532C6D4D dot 2050705 at redhat dot com> <20140321171453 dot GJ4282 at adacore dot com>
On Fri, Mar 21, 2014 at 10:14 AM, Joel Brobecker <brobecker@adacore.com> wrote:
>> +# If we get here and gdb hasn't crashed, the tests pass.
>> +pass "corrupt DWARF"
>
> That's just me but I usually do a "print 1" test, just to make sure
> that even if the testing framework did not detect the GDB process
> dying, the "print 1" test definitely will. Not important on most,
> if not all platforms, but ISTR some odd platforms where this helped.
> That's just a suggestion, you don't have to follow it.
Not that this needs to be added to this patch, but IWBN to codify this
in a utility routine, some tcl proc that does "print 1" or whatever
and verifies the expected result. The point is to encapsulate the
intent in a suitably named function, verify_gdb_alive or some such.