* [Linux-ia64] gdb null ptr
@ 2000-11-02 19:37 Pete Wyckoff
0 siblings, 0 replies; only message in thread
From: Pete Wyckoff @ 2000-11-02 19:37 UTC (permalink / raw)
To: linux-ia64
This is probably the wrong place to fix the bug, but it keeps gdb
from crashing on codes created using sgif90 (Version 0.01.0-11).
The type structure which causes the problem has null for both name and
tag_name. I didn't look far enough to figure out why. Code in question
is tag_type_to_type called from die_type.
Patch against snap-001024 with patches from README.glibc213 and
patch.02[7-9].
How was I using it? Start the mpi code, attach it with gdb, wait for
the FPE to arrive, "Segmentation fault" without patch. With patch,
Program received signal SIGFPE, Arithmetic exception.
0x400000000002c292 in output (ISTATEÊnnot access memory at address 0x0
) at put.F:91
91 gf(i,ic) = gf(i,ic) +
istate is an (implicit) integer*4 parameter passed to subroutine output.
-- Pete
--- src/gdb/dwarf2read.c.orig Thu Nov 2 14:28:21 2000
+++ src/gdb/dwarf2read.c Thu Nov 2 14:28:34 2000
@@ -4522,7 +4522,7 @@
{
const char *nameoftype;
nameoftype = TYPE_NAME(dwarf2_cached_types[hashval]) = NULL ? TYPE_TAG_NAME(dwarf2_cached_types[hashval]) : TYPE_NAME(dwarf2_cached_types[hashval]);
- if (strcmp(attrname, nameoftype) = 0)
+ if (nameoftype && strcmp(attrname, nameoftype) = 0)
{
die->type=dwarf2_cached_types[hashval];
}
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2000-11-02 19:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-11-02 19:37 [Linux-ia64] gdb null ptr Pete Wyckoff
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox