fix: use Node's microtasks policy in node_main.cc (#23153)
Fixes #21515.
This commit is contained in:
parent
3ada079fe3
commit
07654c47ec
3 changed files with 40 additions and 0 deletions
|
@ -146,6 +146,10 @@ int NodeMain(int argc, char* argv[]) {
|
|||
JavascriptEnvironment gin_env(loop);
|
||||
|
||||
v8::Isolate* isolate = gin_env.isolate();
|
||||
// TODO(ckerr) and/or TODO(codebytere) use node::SetIsolateMiscHandlers()
|
||||
node::IsolateSettings is;
|
||||
isolate->SetMicrotasksPolicy(is.policy);
|
||||
|
||||
v8::Isolate::Scope isolate_scope(isolate);
|
||||
v8::Locker locker(isolate);
|
||||
node::Environment* env = nullptr;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue