From 4eb8810a27a710bcfdf15fc03fbb22a65e655aff Mon Sep 17 00:00:00 2001 From: Fedor Indutny Date: Fri, 13 Mar 2015 22:41:26 -0700 Subject: [PATCH] tls: re-enable `.writev()` on TLSWrap Fix the `parallel/test-tls-over-http-tunnel.js` on Windows by re-enabling the accidentally disabled `.writev()` method on TLSWrap. It appears that there is some subtle issue with shutdown timing and it manifests itself when the chunks are written in separate packets. This leads to concurrent `shutdown`/`destroy`, which breaks the test. PR-URL: https://github.com/iojs/io.js/pull/1155 Reviewed-By: Bert Belder --- src/tls_wrap.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/tls_wrap.cc b/src/tls_wrap.cc index 0fab952a2b579b..13ba550398bc06 100644 --- a/src/tls_wrap.cc +++ b/src/tls_wrap.cc @@ -827,7 +827,7 @@ void TLSWrap::Initialize(Handle target, env->SetProtoMethod(t, "enableSessionCallbacks", EnableSessionCallbacks); env->SetProtoMethod(t, "enableHelloParser", EnableHelloParser); - StreamBase::AddMethods(env, t); + StreamBase::AddMethods(env, t, StreamBase::kFlagHasWritev); SSLWrap::AddMethods(env, t); #ifdef SSL_CTRL_SET_TLSEXT_SERVERNAME_CB