summaryrefslogtreecommitdiff
path: root/src/output
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2017-12-13 11:08:42 -0500
committermidipix <writeonce@midipix.org>2017-12-13 11:24:14 -0500
commitf3d26e13d91f3ca06ab3de9714a908596a0e7e36 (patch)
treee66e4d27f55226aab81abfd1fa4018a39e64926f /src/output
parent25e3c0b994fe1cb59ac601dacbded5a3ea953b6e (diff)
downloadperk-f3d26e13d91f3ca06ab3de9714a908596a0e7e36.tar.bz2
perk-f3d26e13d91f3ca06ab3de9714a908596a0e7e36.tar.xz
refactor: struct pe_image_meta: pointers to raw data are now r-prefixed.
Diffstat (limited to 'src/output')
-rw-r--r--src/output/pe_output_export_symbols.c2
-rw-r--r--src/output/pe_output_image_strings.c2
-rw-r--r--src/output/pe_output_image_symbols.c4
3 files changed, 4 insertions, 4 deletions
diff --git a/src/output/pe_output_export_symbols.c b/src/output/pe_output_export_symbols.c
index c8a6de3..1ddef14 100644
--- a/src/output/pe_output_export_symbols.c
+++ b/src/output/pe_output_export_symbols.c
@@ -51,7 +51,7 @@ int pe_output_export_symbols(
if ((pretty_header(cctx,fout)) < 0)
return PERK_FILE_ERROR(dctx);
- mark = m->image.addr;
+ mark = m->r_image.addr;
offset = m->h_edata->sh_virtual_addr - m->h_edata->sh_ptr_to_raw_data;
symrva = (uint32_t *)(mark + m->m_edata.eh_name_ptr_rva - offset);
diff --git a/src/output/pe_output_image_strings.c b/src/output/pe_output_image_strings.c
index 5ffbf93..58fdeaa 100644
--- a/src/output/pe_output_image_strings.c
+++ b/src/output/pe_output_image_strings.c
@@ -32,7 +32,7 @@ int pe_output_image_strings(
dash = "- ";
}
- mark = (char *)meta->image.addr;
+ mark = (char *)meta->r_image.addr;
mark += meta->m_coff.cfh_ptr_to_str_tbl;
cap = mark + meta->m_coff.cfh_size_of_str_tbl;
diff --git a/src/output/pe_output_image_symbols.c b/src/output/pe_output_image_symbols.c
index 7f16d79..7a71b27 100644
--- a/src/output/pe_output_image_symbols.c
+++ b/src/output/pe_output_image_symbols.c
@@ -33,13 +33,13 @@ int pe_output_image_symbols(
dash = "- ";
}
- mark = (char *)meta->image.addr;
+ mark = (char *)meta->r_image.addr;
symtbl = (struct pe_raw_coff_symbol *)(mark + meta->m_coff.cfh_ptr_to_sym_tbl);
for (i=0; i<meta->m_coff.cfh_num_of_syms; i++) {
pe_read_coff_symbol(
&symtbl[i],&symrec,
- &meta->m_coff,meta->image.addr);
+ &meta->m_coff,meta->r_image.addr);
if (fprintf(fout,"%s%s\n",
dash,