From 4be43b90327758560cab9131297377a0ad71ec62 Mon Sep 17 00:00:00 2001 From: isidor Date: Fri, 7 Feb 2020 15:27:17 +0100 Subject: [PATCH] debug: only call `setExceptionBreakpoints` as specified in dap protocol fixes #90001 --- src/vs/workbench/contrib/debug/browser/debugService.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/vs/workbench/contrib/debug/browser/debugService.ts b/src/vs/workbench/contrib/debug/browser/debugService.ts index 82bb31e1916..f6a49d3eeeb 100644 --- a/src/vs/workbench/contrib/debug/browser/debugService.ts +++ b/src/vs/workbench/contrib/debug/browser/debugService.ts @@ -912,7 +912,13 @@ export class DebugService implements IDebugService { private sendExceptionBreakpoints(session?: IDebugSession): Promise { const enabledExceptionBps = this.model.getExceptionBreakpoints().filter(exb => exb.enabled); - return sendToOneOrAllSessions(this.model, session, s => s.sendExceptionBreakpoints(enabledExceptionBps)); + return sendToOneOrAllSessions(this.model, session, async s => { + if (s.capabilities.supportsConfigurationDoneRequest && (!s.capabilities.exceptionBreakpointFilters || s.capabilities.exceptionBreakpointFilters.length === 0)) { + // Only call `setExceptionBreakpoints` as specified in dap protocol #90001 + return; + } + await s.sendExceptionBreakpoints(enabledExceptionBps); + }); } private onFileChanges(fileChangesEvent: FileChangesEvent): void { -- GitLab