summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libdwfl/ChangeLog5
-rw-r--r--libdwfl/dwfl_report_elf.c4
2 files changed, 7 insertions, 2 deletions
diff --git a/libdwfl/ChangeLog b/libdwfl/ChangeLog
index bdd9440f..76733462 100644
--- a/libdwfl/ChangeLog
+++ b/libdwfl/ChangeLog
@@ -1,3 +1,8 @@
+2012-11-20 Jan Kratochvil <jan.kratochvil@redhat.com>
+
+ * dwfl_report_elf.c (__libdwfl_report_elf): Simplify START and BIAS
+ calculation.
+
2012-10-17 Jan Kratochvil <jan.kratochvil@redhat.com>
* dwfl_module_getdwarf.c (mod_verify_build_id): New function with code
diff --git a/libdwfl/dwfl_report_elf.c b/libdwfl/dwfl_report_elf.c
index 35d9f485..174ce7ce 100644
--- a/libdwfl/dwfl_report_elf.c
+++ b/libdwfl/dwfl_report_elf.c
@@ -183,11 +183,11 @@ __libdwfl_report_elf (Dwfl *dwfl, const char *name, const char *file_name,
address_sync = ph->p_vaddr + ph->p_memsz;
if ((base & (ph->p_align - 1)) != 0)
base = (base + ph->p_align - 1) & -ph->p_align;
- start = base + (ph->p_vaddr & -ph->p_align);
+ start = base + vaddr;
break;
}
}
- bias = start - vaddr;
+ bias = base;
for (size_t i = phnum; i-- > 0;)
{