This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: collecting optimized out variables regression (Re: RFA: rewrite dwarf->ax translator (Was: RFC: implement DW_OP_bit_piece))
- 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, Tom Tromey <tromey at redhat dot com>, Stan Shebs <stan at codesourcery dot com>
- Date: Thu, 1 Jul 2010 17:33:50 +0200
- Subject: Re: collecting optimized out variables regression (Re: RFA: rewrite dwarf->ax translator (Was: RFC: implement DW_OP_bit_piece))
- References: <m3ljbgdc4a.fsf@fleche.redhat.com> <m3r5kyl3zt.fsf@fleche.redhat.com> <m3ocfrzxia.fsf_-_@fleche.redhat.com> <201007011343.00392.pedro@codesourcery.com>
On Thu, 01 Jul 2010 14:42:59 +0200, Pedro Alves wrote:
> + if (dlbaton->data == NULL || dlbaton->size == 0)
If SIZE != 0 then DATA must be != NULL otherwise GDB would crash elsewhere.
dwarf2_evaluate_loc_desc is already using this easier to read conditional:
if (size == 0)
which means:
if (dlbaton->size == 0)
Thanks,
Jan