Proposed-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Peter S. Mazinger <ps.m@gmx.net> Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
@@ -231,7 +231,7 @@ static int check_elf_header(ElfW(Ehdr) *const ehdr)
}
/* Check if the target endianness matches the host's endianness */
- byteswap = (ehdr->e_ident[5] == ELFDATAM) ? 0 : 1;
+ byteswap = !(ehdr->e_ident[5] == ELFDATAM);
/* Be very lazy, and only byteswap the stuff we use */
if (byteswap) {