* fix loading of i8086-msdos ELF when the MZ binary in front of it exceeds 64kb

git-svn-id: trunk@39069 -
This commit is contained in:
nickysn 2018-05-20 20:18:00 +00:00
parent 2955ee2dc4
commit a598e17c8a

View File

@ -973,7 +973,7 @@ begin
Exit;
if DosHeader.E_Magic = $5A4D then
begin
E.ImgOffset := DosHeader.e_cp * ParagraphSize;
E.ImgOffset := LongWord(DosHeader.e_cp) * ParagraphSize;
if DosHeader.e_cblp > 0 then
E.ImgOffset := E.ImgOffset + DosHeader.e_cblp - ParagraphSize;
end;