mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-19 17:18:24 +08:00
* dwarf2read.c (per_cu_header_read_in): Simplify, and handle
type units.
This commit is contained in:
@ -1,3 +1,8 @@
|
|||||||
|
2012-06-27 Doug Evans <dje@google.com>
|
||||||
|
|
||||||
|
* dwarf2read.c (per_cu_header_read_in): Simplify, and handle
|
||||||
|
type units.
|
||||||
|
|
||||||
2012-06-26 Doug Evans <dje@google.com>
|
2012-06-26 Doug Evans <dje@google.com>
|
||||||
|
|
||||||
* dwarf2read.c (read_and_check_comp_unit_head): Delete unnecessary
|
* dwarf2read.c (read_and_check_comp_unit_head): Delete unnecessary
|
||||||
|
@ -16808,19 +16808,15 @@ static const struct comp_unit_head *
|
|||||||
per_cu_header_read_in (struct comp_unit_head *cu_headerp,
|
per_cu_header_read_in (struct comp_unit_head *cu_headerp,
|
||||||
struct dwarf2_per_cu_data *per_cu)
|
struct dwarf2_per_cu_data *per_cu)
|
||||||
{
|
{
|
||||||
struct objfile *objfile;
|
|
||||||
struct dwarf2_per_objfile *per_objfile;
|
|
||||||
gdb_byte *info_ptr;
|
gdb_byte *info_ptr;
|
||||||
|
|
||||||
if (per_cu->cu)
|
if (per_cu->cu)
|
||||||
return &per_cu->cu->header;
|
return &per_cu->cu->header;
|
||||||
|
|
||||||
objfile = per_cu->objfile;
|
info_ptr = per_cu->info_or_types_section->buffer + per_cu->offset.sect_off;
|
||||||
per_objfile = objfile_data (objfile, dwarf2_objfile_data_key);
|
|
||||||
info_ptr = per_objfile->info.buffer + per_cu->offset.sect_off;
|
|
||||||
|
|
||||||
memset (cu_headerp, 0, sizeof (*cu_headerp));
|
memset (cu_headerp, 0, sizeof (*cu_headerp));
|
||||||
read_comp_unit_head (cu_headerp, info_ptr, objfile->obfd);
|
read_comp_unit_head (cu_headerp, info_ptr, per_cu->objfile->obfd);
|
||||||
|
|
||||||
return cu_headerp;
|
return cu_headerp;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user