From 06603fe14399f09f2d7f6717cd469bf10a283091 Mon Sep 17 00:00:00 2001 From: Sijie Chen Date: Tue, 11 Jun 2024 17:51:48 +0000 Subject: [PATCH] [CrashReporting] Correct guest arch init Init guest arch to NONE, otherwise Arm32 will be used. Bug: 288392666 Test: NA Change-Id: Ib92b0351401b700a18d03e21a68569c2811d163c --- debuggerd/crash_dump.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/debuggerd/crash_dump.cpp b/debuggerd/crash_dump.cpp index 1c1fb8a59..8dd2b0d73 100644 --- a/debuggerd/crash_dump.cpp +++ b/debuggerd/crash_dump.cpp @@ -83,7 +83,7 @@ using android::base::unique_fd; // This stores guest architecture. When the architecture is supported, tombstone file will output // guest state information. -static Architecture g_guest_arch; +static Architecture g_guest_arch = Architecture::NONE; static bool pid_contains_tid(int pid_proc_fd, pid_t tid) { struct stat st; @@ -789,10 +789,6 @@ int main(int argc, char** argv) { ATRACE_NAME("engrave_tombstone"); unwindstack::ArchEnum regs_arch = unwindstack::ARCH_UNKNOWN; switch (g_guest_arch) { - case Architecture::ARM32: { - regs_arch = unwindstack::ARCH_ARM; - break; - } case Architecture::ARM64: { regs_arch = unwindstack::ARCH_ARM64; break;