mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-07-24 17:35:35 +02:00
Bug 444395 - Breakpoints don't get set for second session.
Change-Id: Ifa857cc2e9de00bb2f2a86b9d5e73536294dd01d Signed-off-by: Marc Khouzam <marc.khouzam@ericsson.com> Reviewed-on: https://git.eclipse.org/r/33517 Reviewed-on: https://git.eclipse.org/r/33573
This commit is contained in:
parent
b92677b149
commit
8d56765e6b
1 changed files with 11 additions and 8 deletions
|
@ -1876,18 +1876,15 @@ public class MIBreakpointsManager extends AbstractDsfService implements IBreakpo
|
|||
List<IExecutionDMContext[]> threads = new ArrayList<IExecutionDMContext[]>(1);
|
||||
|
||||
try {
|
||||
// Retrieve the targets
|
||||
// Retrieve all existing targets.
|
||||
// Note that these targets can be from different debugging sessions since
|
||||
// they are associated with the platform breakpoint.
|
||||
IDsfBreakpointExtension filterExtension = getFilterExtension(breakpoint);
|
||||
IContainerDMContext[] procTargets = filterExtension.getTargetFilters();
|
||||
|
||||
// If no target is present, breakpoint applies to all.
|
||||
if (procTargets.length == 0) {
|
||||
results.add("0"); //$NON-NLS-1$
|
||||
return results;
|
||||
}
|
||||
|
||||
// Extract the thread IDs (if there is none, we are covered)
|
||||
// Extract the thread IDs
|
||||
for (IContainerDMContext procDmc : procTargets) {
|
||||
// Look for a target/process that belongs to our session
|
||||
if (procDmc.equals(bpTargetDmc) || DMContexts.isAncestorOf(procDmc, bpTargetDmc)) {
|
||||
IExecutionDMContext[] threadFilters = filterExtension.getThreadFilters(procDmc);
|
||||
if (threadFilters == null) {
|
||||
|
@ -1913,6 +1910,12 @@ public class MIBreakpointsManager extends AbstractDsfService implements IBreakpo
|
|||
results.add("0"); //$NON-NLS-1$
|
||||
return results;
|
||||
}
|
||||
|
||||
// If there are no threads to filter on, it means the bp applies to the entire process.
|
||||
if (threads.isEmpty()) {
|
||||
results.add("0"); //$NON-NLS-1$
|
||||
return results;
|
||||
}
|
||||
|
||||
for (IExecutionDMContext[] targetThreads : threads) {
|
||||
if (targetThreads != null) {
|
||||
|
|
Loading…
Add table
Reference in a new issue