Pending breakpoint state appears to be incorrectly considered clean sometimes
f73ec093 and 3c58d05b introduced and used QSet<const Breakpoint*> IBreakpointController::m_pending
. 5 years later cf55216e removed the only modification of this set:
- if (b.hasField("addr") && b["addr"].literal() == "<PENDING>") {
- m_pending.insert(breakpoint);
- } else {
- m_pending.remove(breakpoint);
The single use in IBreakpointController::breakpointStateChanged()
was left behind:
if (m_pending.contains(breakpoint)) {
newState = Breakpoint::PendingState;
} else {
newState = Breakpoint::CleanState;
}
Since m_pending
is permanently empty, the check never succeeds and so a pending state might be missed. I could be mistaken and pending state might be handled correctly in some unobvious way. In that case the useless m_pending
variable should be simply removed.
EDIT: m_pending
is part of obsolete API and was scheduled for removal almost 10 years ago. !492 removes it, but is not ready to be merged because of two plugins that still use obsolete API.
Edited by Igor Kushnir