mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 22:14:25 +02:00
* don't crash when reading a Macho-O binary with an unanticipated
structure (patch by Colin Western, mantis #17424) git-svn-id: trunk@15995 -
This commit is contained in:
parent
b938ea0f2a
commit
79fbca8c63
@ -921,7 +921,11 @@ begin
|
|||||||
seek(e.f,e.sechdrofs);
|
seek(e.f,e.sechdrofs);
|
||||||
for i:= 1 to e.nsects do
|
for i:= 1 to e.nsects do
|
||||||
begin
|
begin
|
||||||
|
{$I-}
|
||||||
blockread (e.f, block, sizeof(block));
|
blockread (e.f, block, sizeof(block));
|
||||||
|
{$I+}
|
||||||
|
if IOResult <> 0 then
|
||||||
|
Exit;
|
||||||
if block.cmd = $2 then
|
if block.cmd = $2 then
|
||||||
begin
|
begin
|
||||||
blockread (e.f, symbolsSeg, sizeof(symbolsSeg));
|
blockread (e.f, symbolsSeg, sizeof(symbolsSeg));
|
||||||
|
Loading…
Reference in New Issue
Block a user