diff options
author | midipix <writeonce@midipix.org> | 2017-12-13 11:11:49 -0500 |
---|---|---|
committer | midipix <writeonce@midipix.org> | 2017-12-13 11:24:14 -0500 |
commit | f0d194ac855c0d447702c14440f9a5b8e28de38f (patch) | |
tree | 9bdba1a54ae16cc59fc589aaee1070d5e5dd52a3 | |
parent | ed06fbad97e24dea20e4240054f1cfeb15b15e92 (diff) | |
download | perk-f0d194ac855c0d447702c14440f9a5b8e28de38f.tar.bz2 perk-f0d194ac855c0d447702c14440f9a5b8e28de38f.tar.xz |
refactor: struct pe_expsym: members are now s-prefixed.
-rw-r--r-- | include/perk/perk.h | 8 | ||||
-rw-r--r-- | src/logic/pe_get_image_meta.c | 16 |
2 files changed, 12 insertions, 12 deletions
diff --git a/include/perk/perk.h b/include/perk/perk.h index ccf8d7e..b51b641 100644 --- a/include/perk/perk.h +++ b/include/perk/perk.h @@ -70,10 +70,10 @@ struct pe_raw_image { }; struct pe_expsym { - const char * name; - void * eaddr; - void * maddr; - uint32_t roffset; + const char * s_name; + void * s_eaddr; + void * s_maddr; + uint32_t s_roffset; }; struct pe_meta_stats { diff --git a/src/logic/pe_get_image_meta.c b/src/logic/pe_get_image_meta.c index 12a2658..60b7086 100644 --- a/src/logic/pe_get_image_meta.c +++ b/src/logic/pe_get_image_meta.c @@ -126,10 +126,10 @@ int pe_get_expsym_by_name( if (!(strcmp(sym,name))) { if (expsym) { - expsym->name = sym; - expsym->eaddr = 0; - expsym->maddr = 0; - expsym->roffset = 0; + expsym->s_name = sym; + expsym->s_eaddr = 0; + expsym->s_maddr = 0; + expsym->s_roffset = 0; } return 0; @@ -159,10 +159,10 @@ int pe_get_expsym_by_index( symrva = (uint32_t *)((uintptr_t)m->r_image.map_addr + (m->m_edata.eh_name_ptr_rva - offset)); symaddr = (uintptr_t)m->r_image.map_addr + symrva[index] - offset; - expsym->name = (const char *)symaddr; - expsym->eaddr = 0; - expsym->maddr = 0; - expsym->roffset = 0; + expsym->s_name = (const char *)symaddr; + expsym->s_eaddr = 0; + expsym->s_maddr = 0; + expsym->s_roffset = 0; } return 0; |