Add Process.isProcessFrozen()
Add Process.isProcessFrozen(pid, uid). The method returns true if /sys/fs/cgroup/[apps,system]/uid_<uid>/pid_<pid>/cgroup.freeze is readable and contains the character '1'. Otherwise the method returns false. This means that the method returns false if the caller does not have sufficient privileges. The method queries the "system" path if the UID is less than 10000. It queries the "apps" path if the UID >= 10000. The command "isfrozen <PROCESS>" is now avaiable in the am shell command. It prints "true" or "false" depending on the return value from the new method. Flag: EXEMPT bugfix Bug: 409803220 Test: manual test using 'am' commands to freeze, unfreeze, and query processes. Change-Id: I27d8a82716d593d4e714e375d79a400381765fa8
Loading
Please register or sign in to comment