From: Masahiro Yamada Date: Tue, 4 Feb 2014 01:58:31 +0000 (+0900) Subject: relocate-rela: replace a magic number with sizeof(Elf64_Rela) X-Git-Tag: v2014.04-rc1~77^2~11 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=e60cfd531a5066f95ece02e1e76fa2c6326761b3;p=oweals%2Fu-boot.git relocate-rela: replace a magic number with sizeof(Elf64_Rela) Signed-off-by: Masahiro Yamada Cc: Scott Wood Cc: David Feng Acked-by: Scott Wood --- diff --git a/tools/relocate-rela.c b/tools/relocate-rela.c index 93b4c3923e..670b9fd73a 100644 --- a/tools/relocate-rela.c +++ b/tools/relocate-rela.c @@ -120,7 +120,7 @@ int main(int argc, char **argv) } if (rela_start > rela_end || rela_start < text_base || - (rela_end - rela_start) % 24) { + (rela_end - rela_start) % sizeof(Elf64_Rela)) { fprintf(stderr, "%s: bad rela bounds\n", argv[0]); return 3; }