Skip to content

Commit 4bd8100

Browse files
committed
remove leftover shotgun debugging
1 parent c1cb4c2 commit 4bd8100

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

loader.go

+2-3
Original file line numberDiff line numberDiff line change
@@ -75,9 +75,8 @@ func applyRelocationsARM(f *elf.File, symbols []elf.Symbol, dst []byte, rels []b
7575
offset -= 0x04000000
7676
}
7777

78-
pos := uint64(daddr) + uint64(rel.Off)
79-
delta := int64(sym.Value) - int64(pos)
80-
offset += int32(delta)
78+
pos := daddr + addr(rel.Off)
79+
offset += int32(sym.Value) - int32(pos)
8180

8281
if offset&3 != 0 || offset <= -0x02000000 || offset >= 0x02000000 {
8382
return fmt.Errorf("target offset %08x for symbol %#v out of range", offset, sym)

0 commit comments

Comments
 (0)