Commit 9bea207
child_process: fix memory leak in .fork()
Entries in the `net.Server#_slaves` array that is used to track handles
sent from the master to workers were not deleted when a worker exited,
resulting in a slow but inexorable memory leak.
PR-URL: #15679
Backport-PR-URL: #16586
Fixes: #15651
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>1 parent ad69207 commit 9bea207Copy full SHA for 9bea207
File tree
Expand file treeCollapse file tree
3 files changed
+6
-0
lines changedOpen diff view settings
Filter options
- lib
- internal
- test/parallel
Expand file treeCollapse file tree
3 files changed
+6
-0
lines changedOpen diff view settings
Collapse file
lib/internal/socket_list.js
Copy file name to clipboardExpand all lines: lib/internal/socket_list.js+1Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
8 | 8 | |
9 | 9 | |
10 | 10 | |
| 11 | + |
11 | 12 | |
12 | 13 | |
13 | 14 | |
|
Collapse file
+4Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
1664 | 1664 | |
1665 | 1665 | |
1666 | 1666 | |
| 1667 | + |
| 1668 | + |
| 1669 | + |
| 1670 | + |
1667 | 1671 | |
1668 | 1672 | |
1669 | 1673 | |
|
Collapse file
test/parallel/test-child-process-fork-net2.js
Copy file name to clipboardExpand all lines: test/parallel/test-child-process-fork-net2.js+1Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
156 | 156 | |
157 | 157 | |
158 | 158 | |
| 159 | + |
159 | 160 | |
160 | 161 | |
161 | 162 | |
|
0 commit comments