mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-17 09:39:20 +02:00
+ check for duplicated data sections
This commit is contained in:
parent
6f7c1b5b4e
commit
10b201c506
@ -2220,6 +2220,7 @@ implementation
|
||||
ImportSectionRead: Boolean = false;
|
||||
FunctionSectionRead: Boolean = false;
|
||||
CodeSectionRead: Boolean = false;
|
||||
DataSectionRead: Boolean = false;
|
||||
DataCountSectionRead: Boolean = false;
|
||||
|
||||
DataSegments: array of record
|
||||
@ -2732,6 +2733,12 @@ implementation
|
||||
function ReadDataSection: Boolean;
|
||||
begin
|
||||
Result:=False;
|
||||
if DataSectionRead then
|
||||
begin
|
||||
InputError('Data section is duplicated');
|
||||
exit;
|
||||
end;
|
||||
DataSectionRead:=True;
|
||||
end;
|
||||
|
||||
function ReadDataCountSection: Boolean;
|
||||
|
Loading…
Reference in New Issue
Block a user