summaryrefslogtreecommitdiff
path: root/cmds/dumpstate/dumpstate.cpp
diff options
context:
space:
mode:
author Treehugger Robot <treehugger-gerrit@google.com> 2021-03-19 20:35:52 +0000
committer Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com> 2021-03-19 20:35:52 +0000
commitd61cb088265de43d58a4e151b4c65cc4bebe64fc (patch)
tree98994a5d7ea1fd0dcacc7c92b4435c45ccc59509 /cmds/dumpstate/dumpstate.cpp
parent15010434fd1f2ca9e4a682c132852e77d873e36b (diff)
parentd17fa39d091a27041a29b2652463f8a1fe15e0f1 (diff)
Merge "Let dumpstate also call "cmd input_method tracing save-for-bugreport"" am: d17fa39d09
Original change: https://android-review.googlesource.com/c/platform/frameworks/native/+/1636899 Change-Id: I78a9e4258d894a73db2a685f9d7814eb8cd7aa1b
Diffstat (limited to 'cmds/dumpstate/dumpstate.cpp')
-rw-r--r--cmds/dumpstate/dumpstate.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/cmds/dumpstate/dumpstate.cpp b/cmds/dumpstate/dumpstate.cpp
index f5536970cc..8fd05fb47d 100644
--- a/cmds/dumpstate/dumpstate.cpp
+++ b/cmds/dumpstate/dumpstate.cpp
@@ -3024,11 +3024,14 @@ void Dumpstate::MaybeSnapshotSystemTrace() {
}
void Dumpstate::MaybeSnapshotWinTrace() {
- RunCommand(
- // Empty name because it's not intended to be classified as a bugreport section.
- // Actual tracing files can be found in "/data/misc/wmtrace/" in the bugreport.
- "", {"cmd", "window", "tracing", "save-for-bugreport"},
- CommandOptions::WithTimeout(10).Always().DropRoot().RedirectStderr().Build());
+ // Currently WindowManagerService and InputMethodManagerSerivice support WinScope protocol.
+ for (const auto& service : {"window", "input_method"}) {
+ RunCommand(
+ // Empty name because it's not intended to be classified as a bugreport section.
+ // Actual tracing files can be found in "/data/misc/wmtrace/" in the bugreport.
+ "", {"cmd", service, "tracing", "save-for-bugreport"},
+ CommandOptions::WithTimeout(10).Always().DropRoot().RedirectStderr().Build());
+ }
}
void Dumpstate::onUiIntensiveBugreportDumpsFinished(int32_t calling_uid) {