From a0d86befb5251736af84a5d261ba49948baf7c73 Mon Sep 17 00:00:00 2001 From: Joyee Cheung Date: Mon, 20 May 2019 13:39:21 +0200 Subject: src: reorganize inspector and diagnostics initialization - Split the initialization of the inspector and other diagnostics into `Environment::InitializeInspector()` and `Environment::InitializeDiagnostics()` - these need to be reinitialized separately after snapshot deserialization. - Do not store worker url alongside the inspector parent handle, instead just get it from the handle. - Rename `Worker::profiler_idle_notifier_started_` to `Worker::start_profiler_idle_notifier_` because it stores the state inherited from the parent env to use for initializing itself. PR-URL: https://github.com/nodejs/node/pull/27539 Reviewed-By: Anna Henningsen --- src/node_worker.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/node_worker.h') diff --git a/src/node_worker.h b/src/node_worker.h index 8239826a0e8..0e659a9f522 100644 --- a/src/node_worker.h +++ b/src/node_worker.h @@ -54,7 +54,6 @@ class Worker : public AsyncWrap { private: void OnThreadStopped(); void CreateEnvMessagePort(Environment* env); - const std::string url_; std::shared_ptr per_isolate_opts_; std::vector exec_argv_; @@ -62,7 +61,7 @@ class Worker : public AsyncWrap { MultiIsolatePlatform* platform_; v8::Isolate* isolate_ = nullptr; - bool profiler_idle_notifier_started_; + bool start_profiler_idle_notifier_; uv_thread_t tid_; #if NODE_USE_V8_PLATFORM && HAVE_INSPECTOR -- cgit v1.2.3