From ba396aaf6a4540ca97927b0861913d8de5aa3586 Mon Sep 17 00:00:00 2001 From: Vladimir Morozov Date: Fri, 3 Jun 2022 07:02:34 -0700 Subject: [PATCH] add missing NAPI_CDECL --- src/js_native_api_v8.cc | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/js_native_api_v8.cc b/src/js_native_api_v8.cc index 3d55f41eeed928..eca32f5ef3252f 100644 --- a/src/js_native_api_v8.cc +++ b/src/js_native_api_v8.cc @@ -2519,11 +2519,11 @@ napi_status NAPI_CDECL napi_create_reference(napi_env env, env, value, node_api_reftype_maybe_weak, initial_refcount, result); } -napi_status node_api_create_reference(napi_env env, - napi_value value, - node_api_reftype reftype, - uint32_t initial_refcount, - napi_ref* result) { +napi_status NAPI_CDECL node_api_create_reference(napi_env env, + napi_value value, + node_api_reftype reftype, + uint32_t initial_refcount, + napi_ref* result) { // Omit NAPI_PREAMBLE and GET_RETURN_STATUS because V8 calls here cannot throw // JS exceptions. CHECK_ENV(env); @@ -2552,9 +2552,9 @@ napi_status node_api_create_reference(napi_env env, return napi_clear_last_error(env); } -napi_status node_api_get_reference_type(napi_env env, - napi_ref ref, - node_api_reftype* result) { +napi_status NAPI_CDECL node_api_get_reference_type(napi_env env, + napi_ref ref, + node_api_reftype* result) { // Omit NAPI_PREAMBLE and GET_RETURN_STATUS because V8 calls here cannot throw // JS exceptions. CHECK_ENV(env);