Skip to content

Commit

Permalink
test,n-api: delete strong ref w/o unrefing first
Browse files Browse the repository at this point in the history
Re: #34731
Signed-off-by: Gabriel Schulhof <gabriel.schulhof@intel.com>
  • Loading branch information
Gabriel Schulhof committed Aug 18, 2020
1 parent 0e30c5b commit 2a8342e
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 5 deletions.
4 changes: 0 additions & 4 deletions test/node-api/test_worker_terminate_finalization/test.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,6 @@
'use strict';
const common = require('../../common');

// TODO(addaleax): Run this test once it stops failing under ASAN/valgrind.
// Refs: https://github.com/nodejs/node/issues/34731
common.skip('Reference management in N-API leaks memory');

const { Worker, isMainThread } = require('worker_threads');

if (isMainThread) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ int wrappedNativeData;
napi_ref ref;
void WrapFinalizer(napi_env env, void* data, void* hint) {
uint32_t count;
NAPI_CALL_RETURN_VOID(env, napi_reference_unref(env, ref, &count));
NAPI_CALL_RETURN_VOID(env, napi_delete_reference(env, ref));
}

Expand Down

0 comments on commit 2a8342e

Please sign in to comment.