Skip to content

napi (c not c++) - am i responsible for garbage-collecting external c-buffer passed to napi_create_external_arraybuffer()? #39870

Answered by kaizhu256
kaizhu256 asked this question in General
Discussion options

You must be logged in to vote

nevermind, turns out option1 is correct (user needs to manually garbage collect with free()).

the silent-exit bug was due to something else -- cstring was realloc'd but forgot to set it to new pointer.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by mhdawson
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
node-api Issues and PRs related to the Node-API.
1 participant