CPUInheritance::CPUInheritance(pid_t pid, int cmd)
: destination_(DEST_PROCESS) {
- if (pid == -2 && IsLaunchRequest(cmd)) {
+ if (pid == -2 && IsCPUInheritanceRequired(cmd)) {
int ret = resource_set_cpu_inheritance(gettid(), destination_.c_str(), -1);
if (ret != 0)
_E("resource_set_cpu_inheritance() is failed. error(%d)", ret);
}
}
-bool CPUInheritance::IsLaunchRequest(int cmd) {
+bool CPUInheritance::IsCPUInheritanceRequired(int cmd) {
switch (cmd) {
case APP_START:
case APP_OPEN:
case APP_START_ASYNC:
case APP_SEND_LAUNCH_REQUEST_SYNC:
case RPC_PORT_PREPARE_STUB:
+ case APP_IS_RUNNING:
return true;
default:
return false;