Dumpstate: Avoid to dumps on invalid file node [DO NOT MERGE] am: 0cdf324421
Original change: https://googleplex-android-review.googlesource.com/c/device/google/gs201/+/20400885 Change-Id: I761f6de142652d33925a18ae1efd049c41ba25ac Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
This commit is contained in:
commit
aecc127679
1 changed files with 4 additions and 1 deletions
|
@ -617,7 +617,10 @@ void Dumpstate::dumpTouchSection(int fd) {
|
|||
RunCommandToFd(fd, "Disable Force Touch Active", {"/vendor/bin/sh", "-c", cmd});
|
||||
}
|
||||
|
||||
for (int i = 0; i < 4; i+=2) {
|
||||
for (int i = 0; i < 4; i += 2) { // ftm5
|
||||
snprintf(cmd, sizeof(cmd), "%s", stm_cmd_path[i]);
|
||||
if (!access(cmd, R_OK))
|
||||
continue;
|
||||
snprintf(cmd, sizeof(cmd), "%s", stm_cmd_path[i + 1]);
|
||||
if (!access(cmd, R_OK)) {
|
||||
snprintf(cmd, sizeof(cmd), "echo A0 01 01 > %s", stm_cmd_path[i + 1]);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue