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

Revert handle wrap refed check #6401

Closed
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions src/handle_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,6 @@ void HandleWrap::Unref(const FunctionCallbackInfo<Value>& args) {
}


void HandleWrap::Unrefed(const FunctionCallbackInfo<Value>& args) {
HandleWrap* wrap = Unwrap<HandleWrap>(args.Holder());

bool unrefed = wrap->flags_ & kUnref == 1;
args.GetReturnValue().Set(unrefed);
}


void HandleWrap::Close(const FunctionCallbackInfo<Value>& args) {
Environment* env = Environment::GetCurrent(args);

Expand Down
1 change: 0 additions & 1 deletion src/handle_wrap.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ class HandleWrap : public AsyncWrap {
static void Close(const v8::FunctionCallbackInfo<v8::Value>& args);
static void Ref(const v8::FunctionCallbackInfo<v8::Value>& args);
static void Unref(const v8::FunctionCallbackInfo<v8::Value>& args);
static void Unrefed(const v8::FunctionCallbackInfo<v8::Value>& args);

static inline bool IsAlive(const HandleWrap* wrap) {
return wrap != nullptr && wrap->GetHandle() != nullptr;
Expand Down
1 change: 0 additions & 1 deletion src/pipe_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ void PipeWrap::Initialize(Local<Object> target,
env->SetProtoMethod(t, "close", HandleWrap::Close);
env->SetProtoMethod(t, "unref", HandleWrap::Unref);
env->SetProtoMethod(t, "ref", HandleWrap::Ref);
env->SetProtoMethod(t, "unrefed", HandleWrap::Unrefed);

StreamWrap::AddMethods(env, t);

Expand Down
1 change: 0 additions & 1 deletion src/process_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ class ProcessWrap : public HandleWrap {

env->SetProtoMethod(constructor, "ref", HandleWrap::Ref);
env->SetProtoMethod(constructor, "unref", HandleWrap::Unref);
env->SetProtoMethod(constructor, "unrefed", HandleWrap::Unrefed);

target->Set(FIXED_ONE_BYTE_STRING(env->isolate(), "Process"),
constructor->GetFunction());
Expand Down
1 change: 0 additions & 1 deletion src/signal_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ class SignalWrap : public HandleWrap {
env->SetProtoMethod(constructor, "close", HandleWrap::Close);
env->SetProtoMethod(constructor, "ref", HandleWrap::Ref);
env->SetProtoMethod(constructor, "unref", HandleWrap::Unref);
env->SetProtoMethod(constructor, "unrefed", HandleWrap::Unrefed);
env->SetProtoMethod(constructor, "start", Start);
env->SetProtoMethod(constructor, "stop", Stop);

Expand Down
1 change: 0 additions & 1 deletion src/tcp_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ void TCPWrap::Initialize(Local<Object> target,

env->SetProtoMethod(t, "ref", HandleWrap::Ref);
env->SetProtoMethod(t, "unref", HandleWrap::Unref);
env->SetProtoMethod(t, "unrefed", HandleWrap::Unrefed);

StreamWrap::AddMethods(env, t, StreamBase::kFlagHasWritev);

Expand Down
1 change: 0 additions & 1 deletion src/timer_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ class TimerWrap : public HandleWrap {
env->SetProtoMethod(constructor, "close", HandleWrap::Close);
env->SetProtoMethod(constructor, "ref", HandleWrap::Ref);
env->SetProtoMethod(constructor, "unref", HandleWrap::Unref);
env->SetProtoMethod(constructor, "unrefed", HandleWrap::Unrefed);

env->SetProtoMethod(constructor, "start", Start);
env->SetProtoMethod(constructor, "stop", Stop);
Expand Down
1 change: 0 additions & 1 deletion src/tty_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ void TTYWrap::Initialize(Local<Object> target,

env->SetProtoMethod(t, "close", HandleWrap::Close);
env->SetProtoMethod(t, "unref", HandleWrap::Unref);
env->SetProtoMethod(t, "unrefed", HandleWrap::Unrefed);

StreamWrap::AddMethods(env, t, StreamBase::kFlagNoShutdown);

Expand Down
1 change: 0 additions & 1 deletion src/udp_wrap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,6 @@ void UDPWrap::Initialize(Local<Object> target,

env->SetProtoMethod(t, "ref", HandleWrap::Ref);
env->SetProtoMethod(t, "unref", HandleWrap::Unref);
env->SetProtoMethod(t, "unrefed", HandleWrap::Unrefed);

target->Set(FIXED_ONE_BYTE_STRING(env->isolate(), "UDP"), t->GetFunction());
env->set_udp_constructor_function(t->GetFunction());
Expand Down
33 changes: 0 additions & 33 deletions test/parallel/test-handle-wrap-isrefed-tty.js

This file was deleted.

103 changes: 0 additions & 103 deletions test/parallel/test-handle-wrap-isrefed.js

This file was deleted.