summaryrefslogtreecommitdiff
path: root/rs/java/android/renderscript/ProgramFragmentFixedFunction.java
diff options
context:
space:
mode:
authorqiwang <wangqi_a@xiaomi.com>2019-08-22 11:25:30 +0800
committerChris Wailes <chriswailes@google.com>2019-09-06 14:14:33 -0700
commitae32f7e599aa0e54ceab737a3031c87dff059608 (patch)
treefa7b3a618e9a620df28b211cb1ca61b22b569057 /rs/java/android/renderscript/ProgramFragmentFixedFunction.java
parent156f347db4cd0f199af0ce8a23bfe08a0b295e45 (diff)
Don't clear the output array if it failed to open the proc status file
According to the original documentation, the functions in Process.java should return -1 when the process doesn't exist,this should be detected by Process.readProcLine() when it fails to open the /proc/<pid>/status file. Unfortunately readProcLine() zeroes-out the output array before attempting to open the file, so the expected return value -1 is changed to be 0 when the process doesn't exist. It's inconsistent with the interface description definition, so correct it. Test: try to use Process.getUidForPid(int pid) api to read a non-existent process pid's uid, it will return -1 instead of 0. Merged-In: Ic2ac7defea8b15dd65f907d04e168a1283a4f621 Change-Id: Ic2ac7defea8b15dd65f907d04e168a1283a4f621 Signed-off-by: qiwang <wangqi_a@xiaomi.com>
Diffstat (limited to 'rs/java/android/renderscript/ProgramFragmentFixedFunction.java')
0 files changed, 0 insertions, 0 deletions