summaryrefslogtreecommitdiff
path: root/gdb/somread.c
diff options
context:
space:
mode:
authorJoel Brobecker <brobecker@gnat.com>2003-07-09 18:50:12 +0000
committerJoel Brobecker <brobecker@gnat.com>2003-07-09 18:50:12 +0000
commitc81b613a69dad126009fa6bb8cf09b2cdded0535 (patch)
treeb39f33cd528d7d12de839831836661684ac0c9fc /gdb/somread.c
parent10815f94c1af5c476146b0df8be3d9d79a396990 (diff)
downloadgdb-c81b613a69dad126009fa6bb8cf09b2cdded0535.tar.gz
* somread.c (som_symfile_offsets): Fix compilation error.
Diffstat (limited to 'gdb/somread.c')
-rw-r--r--gdb/somread.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gdb/somread.c b/gdb/somread.c
index cb7b048eafd..e3df6e167a1 100644
--- a/gdb/somread.c
+++ b/gdb/somread.c
@@ -453,7 +453,7 @@ som_symfile_offsets (struct objfile *objfile, struct section_addr_info *addrs)
/* Note: Here is OK to compare with ".text" because this is the
name that gdb itself gives to that section, not the SOM
name. */
- for (i = 0; i < SECT_OFF_MAX && addrs->other[i].name; i++)
+ for (i = 0; i < objfile->num_sections && addrs->other[i].name; i++)
if (strcmp (addrs->other[i].name, ".text") == 0)
break;
text_addr = addrs->other[i].addr;