This is the mail archive of the
mailing list for the GDB project.
Re: Infinite loop in make_cv_type
- From: Richard Earnshaw <rearnsha at arm dot com>
- To: Daniel Jacobowitz <drow at mvista dot com>
- Cc: Richard dot Earnshaw at arm dot com, gdb-patches at sources dot redhat dot com
- Date: Fri, 22 Feb 2002 19:44:44 +0000
- Subject: Re: Infinite loop in make_cv_type
- Organization: ARM Ltd.
- Reply-to: Richard dot Earnshaw at arm dot com
> Any suggestions as to how the stabs reader might be getting ahead of
> itself? Is there another function that might be returning the stabs
> string? I don't think dbx_next_symbol_text has ever returned this
Dead simple really. The stabs on the ARM are broken into very short
strings for historical reasons (there was once an assembler that couldn't
cope with stabs strings of more than about 100 characters). We are simply
running off the end of a stabs string without calling STABS_CONTINUE.
Thus we end up parsing the following string twice: once on the overrun and
the second when dbx_next_symbol_text returns it.
OK to apply?
<date> Richard Earnshaw (firstname.lastname@example.org)
* stabsread.c (read_member_functions): Call STABS_CONTINUE after
skipping a method.
RCS file: /cvs/src/src/gdb/stabsread.c,v
retrieving revision 1.27
diff -p -r1.27 stabsread.c
*** stabsread.c 2002/02/20 18:40:52 1.27
--- stabsread.c 2002/02/22 19:39:29
*************** read_member_functions (struct field_info
*** 3104,3109 ****
--- 3104,3110 ----
+ STABS_CONTINUE (pp, objfile);