summaryrefslogtreecommitdiff
path: root/src/reader
diff options
context:
space:
mode:
Diffstat (limited to 'src/reader')
-rw-r--r--src/reader/pe_read_section_header.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/reader/pe_read_section_header.c b/src/reader/pe_read_section_header.c
index 04a9e61..ed5e1a3 100644
--- a/src/reader/pe_read_section_header.c
+++ b/src/reader/pe_read_section_header.c
@@ -13,21 +13,21 @@
int pe_read_section_header(const struct pe_raw_sec_hdr * p, struct pe_meta_sec_hdr * m)
{
/* name: meta struct conveniently contains null termination */
- memset(m,0,sizeof(m->name));
- memcpy(m,p,sizeof(p->name));
+ memset(m,0,sizeof(m->sh_name));
+ memcpy(m,p,sizeof(p->sh_name));
- m->long_name = 0;
- m->virtual_size = pe_read_long(p->virtual_size);
- m->virtual_addr = pe_read_long(p->virtual_addr);
- m->size_of_raw_data = pe_read_long(p->size_of_raw_data);
- m->ptr_to_raw_data = pe_read_long(p->ptr_to_raw_data);
- m->ptr_to_relocs = pe_read_long(p->ptr_to_relocs);
- m->ptr_to_line_nums = pe_read_long(p->ptr_to_line_nums);
+ m->sh_long_name = 0;
+ m->sh_virtual_size = pe_read_long(p->sh_virtual_size);
+ m->sh_virtual_addr = pe_read_long(p->sh_virtual_addr);
+ m->sh_size_of_raw_data = pe_read_long(p->sh_size_of_raw_data);
+ m->sh_ptr_to_raw_data = pe_read_long(p->sh_ptr_to_raw_data);
+ m->sh_ptr_to_relocs = pe_read_long(p->sh_ptr_to_relocs);
+ m->sh_ptr_to_line_nums = pe_read_long(p->sh_ptr_to_line_nums);
- m->num_of_relocs = pe_read_short(p->num_of_relocs);
- m->num_of_line_nums = pe_read_short(p->num_of_line_nums);
+ m->sh_num_of_relocs = pe_read_short(p->sh_num_of_relocs);
+ m->sh_num_of_line_nums = pe_read_short(p->sh_num_of_line_nums);
- m->characteristics = pe_read_long(p->characteristics);
+ m->sh_characteristics = pe_read_long(p->sh_characteristics);
return 0;
}