summaryrefslogtreecommitdiffstats
path: root/src/util/elf2efi.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/util/elf2efi.c')
-rw-r--r--src/util/elf2efi.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/util/elf2efi.c b/src/util/elf2efi.c
index 3bf6cbf9..29e4f24a 100644
--- a/src/util/elf2efi.c
+++ b/src/util/elf2efi.c
@@ -440,8 +440,8 @@ static void read_elf_file ( const char *name, struct elf_file *elf ) {
/* Check program headers */
if ( ( elf->len < ehdr->e_phoff ) ||
- ( ( elf->len - ehdr->e_phoff ) < ( ehdr->e_phnum *
- ehdr->e_phentsize ) ) ) {
+ ( ( elf->len - ehdr->e_phoff ) <
+ ( ( ( unsigned int ) ehdr->e_phnum ) * ehdr->e_phentsize ) ) ) {
eprintf ( "ELF program headers outside file in %s\n", name );
exit ( 1 );
}