mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-15 23:00:18 +02:00
Codetool: fix endless loop in "Find block begin", when already at start of file. Issue #40326
This commit is contained in:
parent
ac18b36c00
commit
4f1d9530d5
@ -5339,6 +5339,8 @@ begin
|
|||||||
ReadBackTilBlockEnd(true);
|
ReadBackTilBlockEnd(true);
|
||||||
if CursorOnStart then exit(true);
|
if CursorOnStart then exit(true);
|
||||||
end;
|
end;
|
||||||
|
if CurPos.StartPos <= 1 then // Issue #40326
|
||||||
|
break;
|
||||||
ReadPriorAtom;
|
ReadPriorAtom;
|
||||||
until CurPos.StartPos<MinPos;
|
until CurPos.StartPos<MinPos;
|
||||||
end;
|
end;
|
||||||
|
Loading…
Reference in New Issue
Block a user