File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -191,7 +191,8 @@ MaybeLocal<Function> DynamicLibrary::CreateFunction(
191191
192192 FFIFunctionInfo* info = new FFIFunctionInfo ();
193193 info->fn = fn;
194- Local<External> data = External::New (isolate, info);
194+ Local<External> data =
195+ External::New (isolate, info, v8::kExternalPointerTypeTagDefault );
195196 MaybeLocal<Function> maybe_ret =
196197 Function::New (env->context (), DynamicLibrary::InvokeFunction, data);
197198 Local<Function> ret;
@@ -274,8 +275,8 @@ void DynamicLibrary::Close(const FunctionCallbackInfo<Value>& args) {
274275
275276void DynamicLibrary::InvokeFunction (const FunctionCallbackInfo<Value>& args) {
276277 Environment* env = Environment::GetCurrent (args);
277- FFIFunctionInfo* info =
278- static_cast <FFIFunctionInfo*>( args.Data ().As <External>()->Value ());
278+ FFIFunctionInfo* info = static_cast <FFIFunctionInfo*>(
279+ args.Data ().As <External>()->Value (v8:: kExternalPointerTypeTagDefault ));
279280 FFIFunction* fn = info->fn .get ();
280281
281282 if (fn == nullptr || fn->closed || fn->ptr == nullptr ) {
You can’t perform that action at this time.
0 commit comments