mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-09-10 23:57:03 +08:00
* xcoffexec.c (vmap_exec): Don't assume .text and .data are the
first two sections.
This commit is contained in:
@ -1,3 +1,8 @@
|
|||||||
|
Sat May 9 14:47:28 1992 Stu Grossman (grossman at cygnus.com)
|
||||||
|
|
||||||
|
* xcoffexec.c (vmap_exec): Don't assume .text and .data are the
|
||||||
|
first two sections.
|
||||||
|
|
||||||
Fri May 8 11:42:15 1992 Per Bothner (bothner@rtl.cygnus.com)
|
Fri May 8 11:42:15 1992 Per Bothner (bothner@rtl.cygnus.com)
|
||||||
|
|
||||||
* mipsread.c (parse_procedure): Return rather than using
|
* mipsread.c (parse_procedure): Return rather than using
|
||||||
|
@ -629,24 +629,29 @@ register struct ld_info *ldi; {
|
|||||||
vmap_exec ()
|
vmap_exec ()
|
||||||
{
|
{
|
||||||
static bfd *execbfd;
|
static bfd *execbfd;
|
||||||
|
int i;
|
||||||
|
|
||||||
if (execbfd == exec_bfd)
|
if (execbfd == exec_bfd)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
execbfd = exec_bfd;
|
execbfd = exec_bfd;
|
||||||
|
|
||||||
/* First exec section is `.text', second is `.data'. If this is changed,
|
if (!vmap || !exec_ops.to_sections)
|
||||||
then this routine will choke. */
|
error ("vmap_exec: vmap or exec_ops.to_sections == 0\n");
|
||||||
|
|
||||||
if (!vmap || !exec_ops.to_sections ||
|
for (i=0; &exec_ops.to_sections[i] < exec_ops.to_sections_end; i++)
|
||||||
strcmp (exec_ops.to_sections[0].sec_ptr->name, ".text") ||
|
{
|
||||||
strcmp (exec_ops.to_sections[1].sec_ptr->name, ".data"))
|
if (strcmp(".text", exec_ops.to_sections[i].sec_ptr->name) == 0)
|
||||||
|
{
|
||||||
fatal ("aix: Improper exec_ops sections.");
|
exec_ops.to_sections[i].addr += vmap->tstart;
|
||||||
|
exec_ops.to_sections[i].endaddr += vmap->tstart;
|
||||||
exec_ops.to_sections [0].addr += vmap->tstart;
|
}
|
||||||
exec_ops.to_sections [0].endaddr += vmap->tstart;
|
else if (strcmp(".data", exec_ops.to_sections[i].sec_ptr->name) == 0)
|
||||||
exec_ops.to_sections [1].addr += vmap->dstart;
|
{
|
||||||
exec_ops.to_sections [1].endaddr += vmap->dstart;
|
exec_ops.to_sections[i].addr += vmap->dstart;
|
||||||
|
exec_ops.to_sections[i].endaddr += vmap->dstart;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user