From 466b70b16c43d3fe6888b40f1a73f51a06d0edad Mon Sep 17 00:00:00 2001 From: Woongsuk Cho Date: Thu, 24 Aug 2023 15:36:16 +0900 Subject: [PATCH] Call pluginHasLogControl in the initialize VD create log thread in the pluginHasLogControl to redirect stdout,stderr to vlog. To prevent log missing in the candidate process, call pluginHasLogControl in the initialize() function. --- NativeLauncher/launcher/lib/core_runtime.cc | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/NativeLauncher/launcher/lib/core_runtime.cc b/NativeLauncher/launcher/lib/core_runtime.cc index b03b204..af6ddad 100644 --- a/NativeLauncher/launcher/lib/core_runtime.cc +++ b/NativeLauncher/launcher/lib/core_runtime.cc @@ -452,7 +452,10 @@ int CoreRuntime::initialize(const char* appType, LaunchMode launchMode) removeDebugPipe(); } - + // VD has their own signal handler. + if (!pluginHasLogControl()) { + registerSigHandler(); + } __initialized = true; @@ -520,11 +523,6 @@ int CoreRuntime::launch(const char* appId, const char* root, const char* path, i return -1; } - // VD has their own signal handler. - if (!pluginHasLogControl()) { - registerSigHandler(); - } - pluginSetAppInfo(appId, path); // temporal root path is overrided to real application root path -- 2.34.1