fix: uv loop polling when render process reuse enabled (#25869)

This commit is contained in:
Shelley Vohr 2020-10-13 09:19:44 -07:00 committed by GitHub
parent d57cd09f14
commit e8166db9d7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 27 additions and 3 deletions

View file

@ -108,12 +108,12 @@ void ElectronRendererClient::DidCreateScriptContext(
injected_frames_.insert(render_frame);
// If this is the first environment we are creating, prepare the node
// bindings.
if (!node_integration_initialized_) {
node_integration_initialized_ = true;
node_bindings_->Initialize();
node_bindings_->PrepareMessageLoop();
} else if (reuse_renderer_processes_enabled) {
node_bindings_->PrepareMessageLoop();
}
// Setup node tracing controller.
@ -129,7 +129,7 @@ void ElectronRendererClient::DidCreateScriptContext(
// If we have disabled the site instance overrides we should prevent loading
// any non-context aware native module
if (command_line->HasSwitch(switches::kDisableElectronSiteInstanceOverrides))
if (reuse_renderer_processes_enabled)
env->set_force_context_aware(true);
env->set_warn_context_aware(true);