Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: correctly close half-opened socket #6

Merged
merged 1 commit into from
Jul 31, 2019

Conversation

DudaGod
Copy link
Member

@DudaGod DudaGod commented Jul 31, 2019

No description provided.

@@ -131,10 +131,13 @@ module.exports = {
// The pipe below will end proxySocket if socket closes cleanly, but not
// if it errors (eg, vanishes from the net and starts returning
// EHOSTUNREACH). We need to do that explicitly.
socket.on('error', function () {
socket.on('error', function (err) {
console.warn('WARN: socket closed with error:', err);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

а че ворнинг, а не ERROR?

@@ -50,10 +50,12 @@ module.exports = class Interceptor {
this._serverExtensions = this._isCompressed ? acceptExtensions({extensions, isServer: true}) : null;
}

_getDataSender({sender, event, options}) {
_getDataSender({sender, type, event, options}) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

давай тип будем сразу в sender-е хранить

@DudaGod DudaGod force-pushed the dd.support_allow_half_open_socket branch from 518a718 to 1ba7b77 Compare July 31, 2019 11:57
@DudaGod DudaGod force-pushed the dd.support_allow_half_open_socket branch from 1ba7b77 to b1247c6 Compare July 31, 2019 12:02
@DudaGod DudaGod merged commit 502711a into master Jul 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants