Commit 29bcd47
net: fix socket._getpeername
Fixes: #43009
If calling `this._handle.getpeername` returns an error at the first
call, its result shouldn't be cached to `this._peername`.
Signed-off-by: Daeyeon Jeong daeyeon.dev@gmail.com
PR-URL: #43010
Reviewed-By: Paolo Insogna <paolo@cowtech.it>
Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
Reviewed-By: Zeyu "Alex" Yang <himself65@outlook.com>1 parent 781d5e5 commit 29bcd47Copy full SHA for 29bcd47
File tree
Expand file treeCollapse file tree
2 files changed
+27
-3
lines changedOpen diff view settings
Filter options
- lib
- test/parallel
Expand file treeCollapse file tree
2 files changed
+27
-3
lines changedOpen diff view settings
Collapse file
+4-3Lines changed: 4 additions & 3 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
785 | 785 | |
786 | 786 | |
787 | 787 | |
788 | | - |
789 | | - |
790 | | - |
| 788 | + |
| 789 | + |
| 790 | + |
| 791 | + |
791 | 792 | |
792 | 793 | |
793 | 794 | |
|
Collapse file
test/parallel/test-net-remote-address.js
Copy file name to clipboard+23Lines changed: 23 additions & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
| 1 | + |
| 2 | + |
| 3 | + |
| 4 | + |
| 5 | + |
| 6 | + |
| 7 | + |
| 8 | + |
| 9 | + |
| 10 | + |
| 11 | + |
| 12 | + |
| 13 | + |
| 14 | + |
| 15 | + |
| 16 | + |
| 17 | + |
| 18 | + |
| 19 | + |
| 20 | + |
| 21 | + |
| 22 | + |
| 23 | + |
0 commit comments