Fix loading ELF object and shared libs (needs more review/test)

This commit is contained in:
pancake 2014-09-06 11:41:46 +02:00
parent 8ad662fa1a
commit 1983ba24dd

View File

@ -8,6 +8,10 @@ static int r_core_bin_set_cur (RCore *core, RBinFile *binfile);
static ut64 rva (RBin *bin, int va, ut64 paddr, ut64 vaddr, ut64 baddr, ut64 laddr) {
// hackaround to make -1 be va=0 and 0 to be no-laddr
if (baddr == 0) {
// its an object, so load it at base 0
va = 2;
}
if (laddr == UT64_MAX)
va = 0;
switch (va) {