mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-05-27 20:02:42 +02:00
Debugger: fixed a crash in new instruction queue (object removed by nested call)
git-svn-id: trunk@42733 -
This commit is contained in:
parent
3405cd2a57
commit
ba9964e386
@ -848,10 +848,8 @@ begin
|
|||||||
// If a nested readline reads all data, then the outer will have nothing to return.
|
// If a nested readline reads all data, then the outer will have nothing to return.
|
||||||
|
|
||||||
if (FCurrentInstruction = nil) or (FCurrentInstruction.IsCompleted) then begin
|
if (FCurrentInstruction = nil) or (FCurrentInstruction.IsCompleted) then begin
|
||||||
if s <> '' then begin
|
if s <> '' then // Should not happen
|
||||||
//Should not happen
|
|
||||||
DebugLn(DBG_VERBOSE, ['TGDB_IQ: Got Data, but command was finished. Cmd: ', ExeInstr.DebugText, ' Data: ', S]);
|
DebugLn(DBG_VERBOSE, ['TGDB_IQ: Got Data, but command was finished. Cmd: ', ExeInstr.DebugText, ' Data: ', S]);
|
||||||
end;
|
|
||||||
if not FDebugger.ReadLineWasAbortedByNested then
|
if not FDebugger.ReadLineWasAbortedByNested then
|
||||||
DebugLn(DBG_VERBOSE, ['TGDB_IQ: Missing instruction. Not flagged as nested. Cmd: ', ExeInstr.DebugText, ' Data: ', S]);
|
DebugLn(DBG_VERBOSE, ['TGDB_IQ: Missing instruction. Not flagged as nested. Cmd: ', ExeInstr.DebugText, ' Data: ', S]);
|
||||||
break;
|
break;
|
||||||
@ -862,6 +860,9 @@ begin
|
|||||||
|
|
||||||
Skip := False;
|
Skip := False;
|
||||||
HandleGdbDataBeforeInstruction(S, Skip, FCurrentInstruction);
|
HandleGdbDataBeforeInstruction(S, Skip, FCurrentInstruction);
|
||||||
|
// HandleGdbDataBeforeInstruction may execune other Instructions
|
||||||
|
if (FCurrentInstruction = nil) or (FCurrentInstruction.IsCompleted) then
|
||||||
|
break;
|
||||||
|
|
||||||
if (not Skip) and
|
if (not Skip) and
|
||||||
( (not FDebugger.ReadLineTimedOut) or (S <> '') )
|
( (not FDebugger.ReadLineTimedOut) or (S <> '') )
|
||||||
|
Loading…
Reference in New Issue
Block a user