mirror of
https://github.com/nodejs/node.git
synced 2026-10-14 10:26:26 -04:00
src: fix GetCpuProfiler() deprecation warning
Refs: https://github.com/nodejs/node-v8/issues/46 PR-URL: https://github.com/nodejs/node/pull/19989 Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Matheus Marchini <matheus@sthima.com> Reviewed-By: Gus Caplan <me@gus.host> Reviewed-By: Myles Borins <myles.borins@gmail.com>
This commit is contained in:
1 parent
0fc488baf1
commit
fbe6b8500f
1 file changed
+2
-2
+2
-2
@@ -252,12 +252,12 @@ void Environment::CleanupHandles() {
|
||||
void Environment::StartProfilerIdleNotifier() {
|
||||
uv_prepare_start(&idle_prepare_handle_, [](uv_prepare_t* handle) {
|
||||
Environment* env = ContainerOf(&Environment::idle_prepare_handle_, handle);
|
||||
env->isolate()->GetCpuProfiler()->SetIdle(true);
|
||||
env->isolate()->SetIdle(true);
|
||||
});
|
||||
|
||||
uv_check_start(&idle_check_handle_, [](uv_check_t* handle) {
|
||||
Environment* env = ContainerOf(&Environment::idle_check_handle_, handle);
|
||||
env->isolate()->GetCpuProfiler()->SetIdle(false);
|
||||
env->isolate()->SetIdle(false);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user