tls: handle cases where the raw socket is destroyed#49980
Merged
nodejs-github-bot merged 1 commit intonodejs:mainfrom Oct 4, 2023
Merged
tls: handle cases where the raw socket is destroyed#49980nodejs-github-bot merged 1 commit intonodejs:mainfrom
nodejs-github-bot merged 1 commit intonodejs:mainfrom
Conversation
9c7a6df to
c14baa7
Compare
Member
Author
|
cc: @pimterry |
benjamingr
reviewed
Sep 30, 2023
Collaborator
Ensure that the `'close'` event is emitted on a `TLSSocket` when it is created from an existing raw `net.Socket` and the raw socket is not closed cleanly (destroyed). Refs: nodejs@048e0bec5147 Refs: nodejs#49902 (comment) Fixes: nodejs#49902
c14baa7 to
8e51895
Compare
benjamingr
approved these changes
Sep 30, 2023
Member
benjamingr
left a comment
There was a problem hiding this comment.
Actual fix LGTM, I wonder if we shouldn't nextTick the callback in this case since I thhinkk it can be called synchronously in this case and I'm not sure it was possible before
That said, "maybe not 100% inconsistently timed" is still much better than "not sure if called at all"
Member
Author
I thought about that, but it is called after the |
Collaborator
Collaborator
16 tasks
pimterry
reviewed
Oct 1, 2023
Member
pimterry
left a comment
There was a problem hiding this comment.
Good catch! Makes sense, LGTM 👍
This was referenced Oct 2, 2023
joyeecheung
approved these changes
Oct 4, 2023
Collaborator
|
Landed in b1ada0a |
alexfernandez
pushed a commit
to alexfernandez/node
that referenced
this pull request
Nov 1, 2023
Ensure that the `'close'` event is emitted on a `TLSSocket` when it is created from an existing raw `net.Socket` and the raw socket is not closed cleanly (destroyed). Refs: nodejs@048e0bec5147 Refs: nodejs#49902 (comment) Fixes: nodejs#49902 PR-URL: nodejs#49980 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
targos
pushed a commit
that referenced
this pull request
Nov 11, 2023
Ensure that the `'close'` event is emitted on a `TLSSocket` when it is created from an existing raw `net.Socket` and the raw socket is not closed cleanly (destroyed). Refs: 048e0bec5147 Refs: #49902 (comment) Fixes: #49902 PR-URL: #49980 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
debadree25
pushed a commit
to debadree25/node
that referenced
this pull request
Apr 15, 2024
Ensure that the `'close'` event is emitted on a `TLSSocket` when it is created from an existing raw `net.Socket` and the raw socket is not closed cleanly (destroyed). Refs: nodejs@048e0bec5147 Refs: nodejs#49902 (comment) Fixes: nodejs#49902 PR-URL: nodejs#49980 Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Joyee Cheung <joyeec9h3@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.
Ensure that the
'close'event is emitted on aTLSSocketwhen it iscreated from an existing raw
net.Socketand the raw socket is notclosed cleanly (destroyed).
Refs: 048e0bec5147
Refs: #49902 (comment)
Fixes: #49902