* setting breakpoint ignore count implemented via gdb/mi command in the gdb/mi

interface

git-svn-id: trunk@29790 -
This commit is contained in:
nickysn 2015-02-22 02:46:48 +00:00
parent 46695f37b4
commit 8ed6109955
3 changed files with 23 additions and 1 deletions

View File

@ -1795,7 +1795,7 @@ begin
GDBState:=bs_enabled;
Debugger^.BreakpointCondition(GDBIndex, GetStr(Conditions));
If IgnoreCount>0 then
Debugger^.Command('ignore '+IntToStr(GDBIndex)+' '+IntToStr(IgnoreCount));
Debugger^.BreakpointSetIgnoreCount(GDBIndex, IgnoreCount);
If Assigned(Commands) then
begin
{Commands are not handled yet }

View File

@ -60,6 +60,7 @@ type
function BreakpointEnable(BkptNo: LongInt): Boolean;
function BreakpointDisable(BkptNo: LongInt): Boolean;
function BreakpointCondition(BkptNo: LongInt; const ConditionExpr: string): Boolean;
function BreakpointSetIgnoreCount(BkptNo: LongInt; const IgnoreCount: LongInt): Boolean;
procedure SetTBreak(tbreakstring : string);
procedure Backtrace;
function LoadFile(var fn: string): Boolean;
@ -248,6 +249,16 @@ begin
BreakpointCondition := GDB.ResultRecord.Success;
end;
function TGDBController.BreakpointSetIgnoreCount(BkptNo: LongInt; const IgnoreCount: LongInt): Boolean;
var
BkptNoStr, IgnoreCountStr: string;
begin
Str(BkptNo, BkptNoStr);
Str(IgnoreCount, IgnoreCountStr);
Command('-break-after ' + BkptNoStr + ' ' + IgnoreCountStr);
BreakpointSetIgnoreCount := GDB.ResultRecord.Success;
end;
procedure TGDBController.SetTBreak(tbreakstring : string);
begin
Command('-break-insert -t ' + tbreakstring);

View File

@ -58,6 +58,7 @@ type
function BreakpointEnable(BkptNo: LongInt): Boolean;
function BreakpointDisable(BkptNo: LongInt): Boolean;
function BreakpointCondition(BkptNo: LongInt; const ConditionExpr: string): Boolean;
function BreakpointSetIgnoreCount(BkptNo: LongInt; const IgnoreCount: LongInt): Boolean;
procedure SetTBreak(tbreakstring : string);
procedure Backtrace;
{ needed for dos because newlines are only #10 (PM) }
@ -376,6 +377,16 @@ begin
BreakpointCondition := not Error;
end;
function TGDBController.BreakpointSetIgnoreCount(BkptNo: LongInt; const IgnoreCount: LongInt): Boolean;
var
BkptNoStr, IgnoreCountStr: string;
begin
Str(BkptNo, BkptNoStr);
Str(IgnoreCount, IgnoreCountStr);
Command('ignore ' + BkptNoStr + ' ' + IgnoreCountStr);
BreakpointSetIgnoreCount := not Error;
end;
procedure TGDBController.SetTBreak(tbreakstring : string);
begin
Last_breakpoint_number:=0;