This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFC] mdebugread.c: Fix IRIX segfault
- From: Kevin Buettner <kevinb at redhat dot com>
- To: gdb-patches at sources dot redhat dot com
- Date: Wed, 19 Mar 2003 12:52:14 -0700
- Subject: Re: [RFC] mdebugread.c: Fix IRIX segfault
- References: <1030318205742.ZM24869@localhost.localdomain>
I made some small changes to the patch based on some feedback from Joel.
(Joel recommended that issNull be used instead of 0.) Joel also took a
look at the debug info which was problematic before. As I understand it,
my patch should not cause any new difficulties with that code.
I've just committed the patch below.
* mdebugread.c (parse_symbol): For stEnd, we're done counting
when iss is issNull.
Index: mdebugread.c
===================================================================
RCS file: /cvs/src/src/gdb/mdebugread.c,v
retrieving revision 1.43
diff -u -p -r1.43 mdebugread.c
--- mdebugread.c 25 Feb 2003 21:36:18 -0000 1.43
+++ mdebugread.c 19 Mar 2003 19:44:36 -0000
@@ -916,9 +916,13 @@ parse_symbol (SYMR *sh, union aux_ext *a
method whose name is identical to the class name
(in particular constructor method names are different
from the class name). There is therefore no risk that
- this check stops the count on the StEnd of a method. */
- if (strcmp (debug_info->ss + cur_fdr->issBase + tsym.iss,
- name) == 0)
+ this check stops the count on the StEnd of a method.
+
+ Also, assume that we're really at the end when tsym.iss
+ is 0 (issNull). */
+ if (tsym.iss == issNull
+ || strcmp (debug_info->ss + cur_fdr->issBase + tsym.iss,
+ name) == 0)
goto end_of_fields;
break;