mirror of
https://github.com/nodejs/node.git
synced 2025-05-09 21:16:53 +00:00

Verify that napi_remove_wrap and napi_delete_reference should be safe to be called consecutively on the in-out params of napi_wrap. PR-URL: https://github.com/nodejs/node/pull/44754 Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com> Reviewed-By: Michael Dawson <midawson@redhat.com> Reviewed-By: Minwoo Jung <nodecorelab@gmail.com>
11 lines
311 B
JavaScript
11 lines
311 B
JavaScript
'use strict';
|
|
|
|
// This test makes no assertions. It tests that calling napi_remove_wrap and
|
|
// napi_delete_reference consecutively doesn't crash the process.
|
|
|
|
const { buildType } = require('../../common');
|
|
|
|
const addon = require(`./build/${buildType}/test_reference_double_free`);
|
|
|
|
addon.deleteImmediately({});
|