projects
/
deliverable
/
binutils-gdb.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Don't check target is running in remote_target::mourn_inferior
[deliverable/binutils-gdb.git]
/
gdb
/
solib-target.c
diff --git
a/gdb/solib-target.c
b/gdb/solib-target.c
index 113211a92bceb2accf5918b1b9bad1afabf6094a..625f0990d109e44c8081115970022ad040c086bf 100644
(file)
--- a/
gdb/solib-target.c
+++ b/
gdb/solib-target.c
@@
-46,7
+46,7
@@
struct lm_info_target : public lm_info_base
/* The cached offsets for each section of this shared library,
determined from SEGMENT_BASES, or SECTION_BASES. */
/* The cached offsets for each section of this shared library,
determined from SEGMENT_BASES, or SECTION_BASES. */
- section_offsets
*offsets = NULL
;
+ section_offsets
offsets
;
};
typedef std::vector<std::unique_ptr<lm_info_target>> lm_info_vector;
};
typedef std::vector<std::unique_ptr<lm_info_target>> lm_info_vector;
@@
-305,13
+305,11
@@
solib_target_relocate_section_addresses (struct so_list *so,
/* Build the offset table only once per object file. We can not do
it any earlier, since we need to open the file first. */
/* Build the offset table only once per object file. We can not do
it any earlier, since we need to open the file first. */
- if (li->offsets
== NULL
)
+ if (li->offsets
.empty ()
)
{
int num_sections = gdb_bfd_count_sections (so->abfd);
{
int num_sections = gdb_bfd_count_sections (so->abfd);
- li->offsets
- = ((struct section_offsets *)
- xzalloc (SIZEOF_N_SECTION_OFFSETS (num_sections)));
+ li->offsets.assign (num_sections, 0);
if (!li->section_bases.empty ())
{
if (!li->section_bases.empty ())
{
@@
-356,7
+354,7
@@
Could not relocate shared library \"%s\": wrong number of ALLOC sections"),
gdb_assert (so->addr_low <= so->addr_high);
found_range = 1;
}
gdb_assert (so->addr_low <= so->addr_high);
found_range = 1;
}
- li->offsets
->offsets
[i] = li->section_bases[bases_index];
+ li->offsets[i] = li->section_bases[bases_index];
bases_index++;
}
if (!found_range)
bases_index++;
}
if (!found_range)
@@
-377,7
+375,8
@@
Could not relocate shared library \"%s\": no segments"), so->so_name);
ULONGEST orig_delta;
int i;
ULONGEST orig_delta;
int i;
- if (!symfile_map_offsets_to_segments (so->abfd, data, li->offsets,
+ if (!symfile_map_offsets_to_segments (so->abfd, data,
+ li->offsets,
li->segment_bases.size (),
li->segment_bases.data ()))
warning (_("\
li->segment_bases.size (),
li->segment_bases.data ()))
warning (_("\
@@
-414,9
+413,8
@@
Could not relocate shared library \"%s\": bad offsets"), so->so_name);
}
}
}
}
- offset = li->offsets->offsets[gdb_bfd_section_index
- (sec->the_bfd_section->owner,
- sec->the_bfd_section)];
+ offset = li->offsets[gdb_bfd_section_index (sec->the_bfd_section->owner,
+ sec->the_bfd_section)];
sec->addr += offset;
sec->endaddr += offset;
}
sec->addr += offset;
sec->endaddr += offset;
}
This page took
0.023759 seconds
and
4
git commands to generate.