mirror of
https://github.com/nodejs/node.git
synced 2026-11-09 15:11:11 -05:00
src: add nullptr handling for NativeKeyObject
Fixes: https://github.com/nodejs/node/issues/56899 PR-URL: https://github.com/nodejs/node/pull/56900 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Filip Skokan <panva.ip@gmail.com>
This commit is contained in:
1 parent
2244a2776a
commit
0a8e474bdc
1 file changed
+1
@@ -1066,6 +1066,7 @@ void NativeKeyObject::New(const FunctionCallbackInfo<Value>& args) {
|
||||
CHECK_EQ(args.Length(), 1);
|
||||
CHECK(args[0]->IsObject());
|
||||
KeyObjectHandle* handle = Unwrap<KeyObjectHandle>(args[0].As<Object>());
|
||||
CHECK_NOT_NULL(handle);
|
||||
new NativeKeyObject(env, args.This(), handle->Data());
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user