[Debugger] Attempt to limit potential race conditions in DebuggerService.Cleanup()

Fixes bug #11016