Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorlegendecas <legendecas@gmail.com>2021-04-21 20:07:24 +0300
committerMichaƫl Zasso <targos@protonmail.com>2021-09-04 16:14:27 +0300
commit5c473bdc12b35546e3b03b47c70ae14fff90536b (patch)
tree4141bf1b68a2e9ca5687624985b9edf10459caf9 /src
parentf39d93a428c82577c2b69613cdda4e5a780395eb (diff)
src: remove unused guards around node-api reference
PR-URL: https://github.com/nodejs/node/pull/38334 Reviewed-By: Michael Dawson <midawson@redhat.com>
Diffstat (limited to 'src')
-rw-r--r--src/js_native_api_v8.cc3
-rw-r--r--src/js_native_api_v8.h1
2 files changed, 0 insertions, 4 deletions
diff --git a/src/js_native_api_v8.cc b/src/js_native_api_v8.cc
index eda1f516624..703c6bcc2c3 100644
--- a/src/js_native_api_v8.cc
+++ b/src/js_native_api_v8.cc
@@ -627,9 +627,6 @@ v8::Local<v8::Value> Reference::Get() {
}
void Reference::Finalize(bool is_env_teardown) {
- if (is_env_teardown) env_teardown_finalize_started_ = true;
- if (!is_env_teardown && env_teardown_finalize_started_) return;
-
// During env teardown, `~napi_env()` alone is responsible for finalizing.
// Thus, we don't want any stray gc passes to trigger a second call to
// `RefBase::Finalize()`. ClearWeak will ensure that even if the
diff --git a/src/js_native_api_v8.h b/src/js_native_api_v8.h
index 057113f2cb7..91c2eeb9898 100644
--- a/src/js_native_api_v8.h
+++ b/src/js_native_api_v8.h
@@ -433,7 +433,6 @@ class Reference : public RefBase {
static void SecondPassCallback(
const v8::WeakCallbackInfo<SecondPassCallParameterRef>& data);
- bool env_teardown_finalize_started_ = false;
v8impl::Persistent<v8::Value> _persistent;
SecondPassCallParameterRef* _secondPassParameter;
bool _secondPassScheduled;