From: Hwankyu Jhun Date: Thu, 12 Jan 2023 06:47:20 +0000 (+0000) Subject: Print appid for debugging X-Git-Tag: accepted/tizen/unified/20230117.140508~3 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1080ea9ca645a8c5babfdc65982297a3e57ce922;p=platform%2Fcore%2Fappfw%2Flaunchpad.git Print appid for debugging To debug which the application is calling security_manager_prepare_app_v2(), the launchpad prints the application ID. This patch fixes the typo and removes build warning message. Change-Id: I3c38ff369ab4cc01aac2c8fdfd3d1e74c3f490ee Signed-off-by: Hwankyu Jhun --- diff --git a/src/launchpad-parser/launchpad_parser_plugin.cc b/src/launchpad-parser/launchpad_parser_plugin.cc index 135a554..eacfbf2 100644 --- a/src/launchpad-parser/launchpad_parser_plugin.cc +++ b/src/launchpad-parser/launchpad_parser_plugin.cc @@ -54,7 +54,7 @@ int LaunchpadParser::WriteToFile(std::string pkgid) { if (i->GetPreloadLib().size() > 0) { out_file << "EXTRA_ARRAY preload \n"; for (auto& lib : i->GetPreloadLib()) { - out_file << "EXTRA_ARRAY_VAL "LIBDIR"/" + lib + "\n"; + out_file << "EXTRA_ARRAY_VAL " LIBDIR "/" + lib + "\n"; } } out_file.close(); diff --git a/src/launchpad-process-pool/src/launchpad.c b/src/launchpad-process-pool/src/launchpad.c index 39c52f9..be6ab2a 100644 --- a/src/launchpad-process-pool/src/launchpad.c +++ b/src/launchpad-process-pool/src/launchpad.c @@ -1338,9 +1338,9 @@ static int __prepare_exec(const char *appid, const char *app_path, /* SET PRIVILEGES*/ enabled_light_user = bundle_get_val(kb, AUL_K_ENABLED_LIGHT_USER); - _W("security_manager_prepare_app2 ++"); + _W("security_manager_prepare_app2 ++ %s", appid); ret = security_manager_prepare_app2(appid, enabled_light_user); - _W("security_manager_prepare_app2 --"); + _W("security_manager_prepare_app2 -- %s", appid); if (ret != SECURITY_MANAGER_SUCCESS) return PAD_ERR_REJECTED; diff --git a/src/lib/launchpad/src/launchpad_lib.c b/src/lib/launchpad/src/launchpad_lib.c index 7980efc..9bd3832 100644 --- a/src/lib/launchpad/src/launchpad_lib.c +++ b/src/lib/launchpad/src/launchpad_lib.c @@ -77,7 +77,7 @@ static int __prepare_exec(const char *appid, const char *app_path, return -1; /* SET PRIVILEGES*/ - SECURE_LOGD("[candidata] appid : %s / pkg_type : %s / app_path : %s", + SECURE_LOGD("[candidate] appid : %s / pkg_type : %s / app_path : %s", appid, pkg_type, app_path); if (global) @@ -96,9 +96,9 @@ static int __prepare_exec(const char *appid, const char *app_path, return -1; enabled_light_user = bundle_get_val(kb, AUL_K_ENABLED_LIGHT_USER); - _W("security_manager_prepare_app2 ++"); + _W("security_manager_prepare_app2 ++ %s", appid); ret = security_manager_prepare_app2(appid, enabled_light_user); - _W("security_manager_prepare_app2 --"); + _W("security_manager_prepare_app2 -- %s", appid); if (ret != SECURITY_MANAGER_SUCCESS) { _E("Failed to set privileges %s:%d", appid, ret); return -1;