lib: make sure close the net server#51929
Merged
nodejs-github-bot merged 1 commit intonodejs:mainfrom Mar 3, 2024
Merged
Conversation
Collaborator
|
Review requested:
|
Collaborator
anonrig
approved these changes
Mar 1, 2024
ShogunPanda
approved these changes
Mar 1, 2024
benjamingr
approved these changes
Mar 1, 2024
marco-ippolito
approved these changes
Mar 1, 2024
Member
|
Does it work if the user does something like this? net.createServer().listen(9999, 'localhost').close().listen(8888, 'localhost'); |
Contributor
Author
|
Yes, |
Collaborator
|
Landed in 29ec7e9 |
targos
pushed a commit
that referenced
this pull request
Mar 7, 2024
PR-URL: #51929 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io> Reviewed-By: Paolo Insogna <paolo@cowtech.it> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
richardlau
pushed a commit
that referenced
this pull request
Mar 25, 2024
PR-URL: #51929 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io> Reviewed-By: Paolo Insogna <paolo@cowtech.it> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
richardlau
pushed a commit
that referenced
this pull request
Mar 25, 2024
PR-URL: #51929 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io> Reviewed-By: Paolo Insogna <paolo@cowtech.it> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Merged
rdw-msft
pushed a commit
to rdw-msft/node
that referenced
this pull request
Mar 26, 2024
PR-URL: nodejs#51929 Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io> Reviewed-By: Paolo Insogna <paolo@cowtech.it> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Marco Ippolito <marcoippolito54@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.
If perform asynchronous operations in the
listenfunction ofnet.js(executedns.lookupor ask the main process to create a server), the server will not close properly.The example is as follows.
See
node/lib/net.js
Line 2092 in c08b797
make -j4 test(UNIX), orvcbuild test(Windows) passes