-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Open
Labels
P2A bug or feature request we're likely to work onA bug or feature request we're likely to work onanalyzer-stabilityarea-devexpFor issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages.For issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages.dds-dapDDS issues related to the Debug Adapter Protocol (DAP) implementationDDS issues related to the Debug Adapter Protocol (DAP) implementationtriagedIssue has been triaged by sub teamIssue has been triaged by sub teamtype-enhancementA request for a change that isn't a bugA request for a change that isn't a bug
Description
On disconnection, DAP kills all pids:
sdk/pkg/dds/lib/src/dap/adapters/mixins.dart
Lines 41 to 47 in 7685ec3
void terminatePids(ProcessSignal signal) { | |
// TODO(dantup): In Dart-Code DAP, we first try again with sigint and wait | |
// for a few seconds before sending sigkill. | |
for (var pid in pidsToTerminate) { | |
Process.killPid(pid, signal); | |
} | |
} |
However, this set of pids contains the VM pid, which defaults to-1
if it was not set:
sdk/pkg/vm_service/lib/src/vm_service.dart
Line 8570 in 7685ec3
pid = json['pid'] ?? -1; |
On Linux, killing -1
is a special case that means "kill all the process that you can." We had a case where this was killing a bunch of running processes on a users machine.
Metadata
Metadata
Assignees
Labels
P2A bug or feature request we're likely to work onA bug or feature request we're likely to work onanalyzer-stabilityarea-devexpFor issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages.For issues related to the analysis server, IDE support, linter, `dart fix`, and diagnostic messages.dds-dapDDS issues related to the Debug Adapter Protocol (DAP) implementationDDS issues related to the Debug Adapter Protocol (DAP) implementationtriagedIssue has been triaged by sub teamIssue has been triaged by sub teamtype-enhancementA request for a change that isn't a bugA request for a change that isn't a bug