diff --git a/software/libdyld/dyld.c b/software/libdyld/dyld.c index 50a48f2fd..c6bdae486 100644 --- a/software/libdyld/dyld.c +++ b/software/libdyld/dyld.c @@ -43,7 +43,8 @@ static int fixup_rela(struct dyld_info *info, Elf32_Rela *rela, return 0; } - *(Elf32_Addr*)(info->base + rela->r_offset) = value; + memcpy((Elf32_Addr*)(info->base + rela->r_offset), &value, + sizeof(Elf32_Addr)); return 1; }