FpDbg: fix only skip 0, if they are leading (invalid, but existing Leb128)

git-svn-id: trunk@42919 -
This commit is contained in:
martin 2013-09-24 09:16:07 +00:00
parent 9c0cdf5a6b
commit 424c549d0c

View File

@ -1138,13 +1138,12 @@ begin
TableListIndex := 0;
TableListLen := Length(FTableList);
while (LEB128 > APointer) and ((LEB128^ and $7f) = 0) do
dec(LEB128);
// LeadByte
while LEB128 > APointer do begin
b := LEB128^ and $7f;
if b = 0 then begin
dec(LEB128);
continue;
end;
Assert(TableListIndex < TableListLen);
e := @FTableList[TableListIndex];
@ -1229,14 +1228,13 @@ begin
end;
LEB128End := LEB128;
while (LEB128 > APointer) and ((LEB128^ and $7f) = 0) do
dec(LEB128);
TableListIndex := 0;
// LeadByte
while LEB128 > APointer do begin
b := LEB128^ and $7f;
if b = 0 then begin
dec(LEB128);
continue;
end;
Assert(TableListIndex < TableListLen);
e := @FTableList[TableListIndex];