net: net.Server.listen() avoid operations on null when fail#23920
Closed
oyyd wants to merge 2 commits intonodejs:masterfrom
Closed
net: net.Server.listen() avoid operations on null when fail#23920oyyd wants to merge 2 commits intonodejs:masterfrom
net.Server.listen() avoid operations on null when fail#23920oyyd wants to merge 2 commits intonodejs:masterfrom
Conversation
When `net.Server` fails to create a new handle, an error shall be emitted in the next tick. Therefore, we make `net.Server.listen()` directly return to avoid following operations on `null` `this._handle`. Fixes: nodejs#23917
richardlau
approved these changes
Oct 27, 2018
Contributor
danbev
approved these changes
Oct 30, 2018
Contributor
Author
|
Tests failed seems unrelated. |
Member
No, the test failures on Windows are definitely related: |
Contributor
Author
|
@richardlau Yes. Sorry for the negligence, will look into this. |
Contributor
Author
|
Although I don't have a windows desktop on hand until the day after tomorrow, I have updated the test to make it emit an "EADDRINUSE" error explicitly. Hopefully it will work on windows. @richardlau Thanks again for the reminding. |
Member
Member
|
Landed in 3458e65 |
Trott
pushed a commit
to Trott/io.js
that referenced
this pull request
Nov 6, 2018
When `net.Server` fails to create a new handle, an error shall be emitted in the next tick. Therefore, we make `net.Server.listen()` directly return to avoid following operations on `null` `this._handle`. Fixes: nodejs#23917 PR-URL: nodejs#23920 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
targos
pushed a commit
that referenced
this pull request
Nov 6, 2018
When `net.Server` fails to create a new handle, an error shall be emitted in the next tick. Therefore, we make `net.Server.listen()` directly return to avoid following operations on `null` `this._handle`. Fixes: #23917 PR-URL: #23920 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
This was referenced Nov 15, 2018
codebytere
pushed a commit
that referenced
this pull request
Nov 29, 2018
When `net.Server` fails to create a new handle, an error shall be emitted in the next tick. Therefore, we make `net.Server.listen()` directly return to avoid following operations on `null` `this._handle`. Fixes: #23917 PR-URL: #23920 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
MylesBorins
pushed a commit
that referenced
this pull request
Nov 29, 2018
When `net.Server` fails to create a new handle, an error shall be emitted in the next tick. Therefore, we make `net.Server.listen()` directly return to avoid following operations on `null` `this._handle`. Fixes: #23917 PR-URL: #23920 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
Merged
MylesBorins
pushed a commit
that referenced
this pull request
Dec 3, 2018
When `net.Server` fails to create a new handle, an error shall be emitted in the next tick. Therefore, we make `net.Server.listen()` directly return to avoid following operations on `null` `this._handle`. Fixes: #23917 PR-URL: #23920 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When
net.Serverfails to create a new handle, an error shall be emitted in the next tick. Therefore, we makenet.Server.listen()directly return to avoid following operations onnullthis._handle.Fixes: #23917
Checklist
make -j4 test(UNIX), orvcbuild test(Windows) passes