This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
Other format: | [Raw text] |
On Mon, Jul 14, 2008 at 10:42 AM, Daniel Jacobowitz <drow@false.org> wrote: > There's nothing special about zero. It's just an unreadable memory > address; the same problem will reappear with any other invalid > pointer. There is something special about zero -- it very frequently occurs in correct C++ programs :) > So if we use TRY_CATCH and RETURN_MASK_ERROR around the call to > current_cp_abi.rtti_type, we can return NULL in the error case. Done. I've also added a "non-zero but invalid" pointer test at ~0UL. Is there a "canonical" invalid address I should be testing instead? Thanks, -- Paul Pluzhnikov ChangeLog 2008-07-14 Paul Pluzhnikov <ppluzhnikov@google.com> PR gdb/2477 * cp-abi.c (value_virtual_fn_field): Handle invalid pointers. testsuite/ChangeLog 2008-07-14 Paul Pluzhnikov <ppluzhnikov@google.com> * gdb.cp/class2.exp, gdb.cp/class2.cc: Test for PR2477.
Attachment:
gdb-patch-2477-20080714-2.txt
Description: Text document
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |