1 --- gdb-4.18/gdb/exec.c.sparc Fri Jan 8 15:03:10 1999
2 +++ gdb-4.18/gdb/exec.c Wed Apr 14 09:59:24 1999
4 #endif /* 0, Stu's implementation */
5 for (p = target->to_sections; p < target->to_sections_end; p++)
9 +#if defined(__sparc__)
10 + if (! strcmp (p->the_bfd_section->name, ".interp"))
14 if (overlay_debugging && section && p->the_bfd_section &&
15 strcmp (section->name, p->the_bfd_section->name) != 0)
16 continue; /* not the section we need */
17 if (memaddr >= p->addr)
18 - if (memend <= p->endaddr)
19 + if (memend <= p->endaddr + slop)
21 /* Entire transfer is within this section. */
22 res = xfer_fn (p->bfd, p->the_bfd_section, myaddr,
23 --- gdb-4.18/bfd/section.c.sparc Tue Jun 30 13:09:28 1998
24 +++ gdb-4.18/bfd/section.c Wed Apr 14 09:59:24 1999
31 if (section->flags & SEC_CONSTRUCTOR)
35 /* Even if reloc_done is true, this function reads unrelocated
36 contents, so we want the raw size. */
37 - sz = section->_raw_size;
38 +#if defined(__sparc__)
39 + if (! strcmp (section->name, ".interp"))
42 + sz = section->_raw_size + slop;
43 if ((bfd_size_type) offset > sz || count > sz || offset + count > sz)
46 --- gdb-4.18/bfd/libbfd.c.sparc Thu Feb 4 21:29:32 1999
47 +++ gdb-4.18/bfd/libbfd.c Wed Apr 14 09:59:24 1999
48 @@ -1152,9 +1152,14 @@
55 - if ((bfd_size_type)(offset+count) > section->_raw_size
56 +#if defined(__sparc__)
57 + if (! strcmp (section->name, ".interp"))
60 + if ((bfd_size_type)(offset+count) > (section->_raw_size + slop)
61 || bfd_seek(abfd, (file_ptr)(section->filepos + offset), SEEK_SET) == -1
62 || bfd_read(location, (bfd_size_type)1, count, abfd) != count)
63 return (false); /* on error */