Commit 1a5a19d6 authored by Gabriel Schulhof's avatar Gabriel Schulhof
Browse files

n-api: back up env before finalize

Heed the comment to not use fields of a Reference after calling its
finalize callback, because such a call may destroy the Reference.

Fixes: https://github.com/nodejs/node/issues/19673
PR-URL: https://github.com/nodejs/node/pull/19718


Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
Reviewed-By: default avatarColin Ihrig <cjihrig@gmail.com>
parent ed86cc57
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment