summaryrefslogtreecommitdiff
path: root/basctl
diff options
context:
space:
mode:
authorNiklas Johansson <sleeping.pillow@gmail.com>2011-11-30 13:33:26 +0100
committerEike Rathke <erack@redhat.com>2011-11-30 13:33:26 +0100
commit0083479a80de831b0ae90877aa4f5d6c4670eb49 (patch)
treec616a8c51eb9b31d9a321f1229f223b3d54e65f1 /basctl
parentc593018f6f2deec8eb98880ac89f19b59a3aee1f (diff)
Fixed fdo#42778 pass count in Manage Breakpoints and crash in dialog
When entering pass count 2 it is expected that the breakpoint is passed two times before breaking not to break the second time. Also fixed a crash due to dangling pointers of breakpoints.
Diffstat (limited to 'basctl')
-rw-r--r--basctl/source/basicide/baside2.cxx2
-rw-r--r--basctl/source/basicide/bastypes.cxx2
2 files changed, 2 insertions, 2 deletions
diff --git a/basctl/source/basicide/baside2.cxx b/basctl/source/basicide/baside2.cxx
index e963871c9bc8..0f425cf439b4 100644
--- a/basctl/source/basicide/baside2.cxx
+++ b/basctl/source/basicide/baside2.cxx
@@ -722,7 +722,7 @@ long ModulWindow::BasicBreakHdl( StarBASIC* pBasic )
if ( pBrk )
{
pBrk->nHitCount++;
- if ( pBrk->nHitCount < pBrk->nStopAfter && GetBasic()->IsBreak() )
+ if ( pBrk->nHitCount <= pBrk->nStopAfter && GetBasic()->IsBreak() )
return aStatus.nBasicFlags; // go on...
}
diff --git a/basctl/source/basicide/bastypes.cxx b/basctl/source/basicide/bastypes.cxx
index 008fa996fddc..b1a67099df86 100644
--- a/basctl/source/basicide/bastypes.cxx
+++ b/basctl/source/basicide/bastypes.cxx
@@ -287,7 +287,7 @@ void BreakPointList::transfer(BreakPointList & rList)
reset();
for (size_t i = 0; i < rList.size(); ++i)
maBreakPoints.push_back( rList.at( i ) );
- rList.reset();
+ rList.clear();
}
void BreakPointList::InsertSorted( BreakPoint* pNewBrk )