-
Notifications
You must be signed in to change notification settings - Fork 1.8k
[CP] [vm] Fix leakage of file system watcher related data structures #52793
Copy link
Copy link
Closed
Labels
area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.cherry-pick-approvedLabel for approved cherrypick requestLabel for approved cherrypick requestcherry-pick-mergedCherry-pick has been merged to the stable or beta branch.Cherry-pick has been merged to the stable or beta branch.cherry-pick-reviewIssue that need cherry pick triage to approveIssue that need cherry pick triage to approve
Metadata
Metadata
Labels
area-vmUse area-vm for VM related issues, including code coverage, and the AOT and JIT backends.Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends.cherry-pick-approvedLabel for approved cherrypick requestLabel for approved cherrypick requestcherry-pick-mergedCherry-pick has been merged to the stable or beta branch.Cherry-pick has been merged to the stable or beta branch.cherry-pick-reviewIssue that need cherry pick triage to approveIssue that need cherry pick triage to approve
Type
Fields
Give feedbackNo fields configured for issues without a type.
Commit(s) to merge
3dd9389
Target
stable
Prepared changelist for beta/stable
https://dart-review.googlesource.com/c/sdk/+/311521
Issue Description
Without this fix, there is a bad leak of
_Closureobjects when using overlappingDirectory.watchstreams. This change switches aStream.pipeusage toStream.listen, and cancels subscriptions.What is the fix
The fix is to change how these watch events are listened to, and canceling subscriptions.
Why cherry-pick
This memory leak can be very prevalent in the Dart analyzer, and memory usage (including leaks) is a top issue for users of Dart analyzer.
Risk
low
Issue link(s)
#52703
Extra Info
No response