diff --git a/src/boot/pe.c b/src/boot/pe.c index 00739a7c74..9af6ca0dd4 100644 --- a/src/boot/pe.c +++ b/src/boot/pe.c @@ -253,7 +253,7 @@ static void pe_locate_sections_internal( j->VirtualSize, device_table, device, - i)) + (PTR_TO_SIZE(j) - PTR_TO_SIZE(section_table)) / sizeof(*j))) continue; }