mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-13 11:29:19 +02:00
fpdebug: check for bounds, before accessing
git-svn-id: trunk@49086 -
This commit is contained in:
parent
2c26f71ea9
commit
311acd5b58
@ -2648,7 +2648,8 @@ begin
|
|||||||
end;
|
end;
|
||||||
exit;
|
exit;
|
||||||
end;
|
end;
|
||||||
Result := t2.OrdHighBound - t2.OrdLowBound + 1;
|
if t2.HasBounds then
|
||||||
|
Result := Integer(t2.OrdHighBound - t2.OrdLowBound + 1);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TFpDwarfValueArray.GetMemberCountEx(AIndex: array of Int64): Integer;
|
function TFpDwarfValueArray.GetMemberCountEx(AIndex: array of Int64): Integer;
|
||||||
@ -3505,7 +3506,7 @@ begin
|
|||||||
InitLocParserData.ObjectDataAddrPush := False;
|
InitLocParserData.ObjectDataAddrPush := False;
|
||||||
if assigned(AValueObj) and LocationFromTag(DW_AT_upper_bound, AValueObj, AnAddress, @InitLocParserData, InformationEntry, True) then begin
|
if assigned(AValueObj) and LocationFromTag(DW_AT_upper_bound, AValueObj, AnAddress, @InitLocParserData, InformationEntry, True) then begin
|
||||||
FHighBoundState := rfConst;
|
FHighBoundState := rfConst;
|
||||||
FHighBoundConst := AnAddress.Address;
|
FHighBoundConst := Int64(AnAddress.Address);
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
begin
|
begin
|
||||||
|
Loading…
Reference in New Issue
Block a user