mirror of
https://github.com/nodejs/node.git
synced 2026-11-27 17:52:27 -05:00
node-api: add missing initialization of last error
- Add missing initiatlization of last error which was reported by coverity. Signed-off-by: Michael Dawson <mdawson@devrus.com> PR-URL: https://github.com/nodejs/node/pull/41290 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Minwoo Jung <nodecorelab@gmail.com>
This commit is contained in:
1 parent
874000ff6b
commit
03490cb311
1 file changed
+1
@@ -56,6 +56,7 @@ struct napi_env__ {
|
||||
: isolate(context->GetIsolate()),
|
||||
context_persistent(isolate, context) {
|
||||
CHECK_EQ(isolate, context->GetIsolate());
|
||||
napi_clear_last_error(this);
|
||||
}
|
||||
virtual ~napi_env__() {
|
||||
// First we must finalize those references that have `napi_finalizer`
|
||||
|
||||
Reference in new issue
Block a user