forked from openkylin/platform_build
runhat: use /data/local/tmp
Use /data/local/tmp for runhat reports, instead of the sdcard. system_server isn't allowed to handle sdcard file descriptors, since the sdcard could be ejected at any time, causing the kernel to kill the system process. This addresses the following SELinux denial: W/main ( 9906): type=1400 audit(0.0:16): avc: denied { read write } for path="/mnt/shell/emulated/0/hprof-600" dev="fuse" ino=3077890536 scontext=u:r:system_server:s0 tcontext=u:object_r:fuse:s0 tclass=file Bug: 16375996 Change-Id: I4c2053c327526c2f8e6812f4ed911a712ae9a9b8
This commit is contained in:
parent
3e72ed17a5
commit
9948b1e9ed
|
@ -1248,9 +1248,7 @@ function runhat()
|
|||
fi
|
||||
|
||||
# issue "am" command to cause the hprof dump
|
||||
local sdcard=$(adb ${adbOptions} shell echo -n '$EXTERNAL_STORAGE')
|
||||
local devFile=$sdcard/hprof-$targetPid
|
||||
#local devFile=/data/local/hprof-$targetPid
|
||||
local devFile=/data/local/tmp/hprof-$targetPid
|
||||
echo "Poking $targetPid and waiting for data..."
|
||||
echo "Storing data at $devFile"
|
||||
adb ${adbOptions} shell am dumpheap $targetPid $devFile
|
||||
|
|
Loading…
Reference in New Issue