Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix memory leak on Linux/Darwin platforms #1572

Merged
merged 1 commit into from
Jun 24, 2018
Merged

Fix memory leak on Linux/Darwin platforms #1572

merged 1 commit into from
Jun 24, 2018

Conversation

shodan8192
Copy link

Poller should be deleted by WeakCallback (attached during wrapping), but v8 doc state : "There is no guarantee as to when or even if the callback is invoked" and indeed that never happens.

Changes consist code to allow deleting Poller object explicitly from JavaScript.

@codecov
Copy link

codecov bot commented Jun 1, 2018

Codecov Report

Merging #1572 into master will decrease coverage by 0.74%.
The diff coverage is 0%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1572      +/-   ##
==========================================
- Coverage   75.61%   74.87%   -0.75%     
==========================================
  Files          15       15              
  Lines         808      816       +8     
  Branches      149      149              
==========================================
  Hits          611      611              
- Misses        197      205       +8
Impacted Files Coverage Δ
lib/bindings/darwin.js 64.4% <0%> (-1.12%) ⬇️
lib/bindings/linux.js 65% <0%> (-1.11%) ⬇️
lib/bindings/poller.js 12.9% <0%> (-1.39%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d829ada...25964c5. Read the comment docs.

@reconbot
Copy link
Member

I wish this fixed the issue for when the port goes out of scope but it's a great step in that direction.

@reconbot reconbot merged commit 9006bd6 into serialport:master Jun 24, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Dec 21, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants