fix: minidump-2-core doesn't work for new arm64 dumps

The app will check if process_architecture is ARM64_OLD which is 0x8003
but newman is a new arch which is ARM64 (0x12)
We can fix the issue by checking both values

Test: "/google/src/cloud/zyanwu/latest/google3/blaze-bin/chrome/dongle/platform/tools/minidump --crash_report_id=49ed111b84c0736e --crash_server=crash --build_number=265669 --build_branch=1.56 --product=newman-user --eureka_root=/usr/local/google/home/zyanwu/eureka --symbol_cache_dir=/usr/local/google/home/zyanwu/android/debug/symbols --debug" can work and it can convert the minidump to core dump then load gdb.
Bug: 199144156
Change-Id: I1590a5b617e55ae8347aad426ba5b636ff6dcdfb
Reviewed-on: https://chromium-review.googlesource.com/c/breakpad/breakpad/+/3146740
Reviewed-by: Sterling Augustine <saugustine@google.com>
Reviewed-by: Nelson Billing <nbilling@google.com>
This commit is contained in:
Zyan Wu 2021-09-08 17:45:07 +08:00 committed by Ivan Penkov
parent 1e093103ca
commit 94c4208821

View file

@ -600,7 +600,8 @@ ParseSystemInfo(const Options& options, CrashedProcess* crashinfo,
exit(1);
}
#elif defined(__aarch64__)
if (sysinfo->processor_architecture != MD_CPU_ARCHITECTURE_ARM64_OLD) {
if (sysinfo->processor_architecture != MD_CPU_ARCHITECTURE_ARM64_OLD &&
sysinfo->processor_architecture != MD_CPU_ARCHITECTURE_ARM64) {
fprintf(stderr,
"This version of minidump-2-core only supports ARM (64bit).\n");
exit(1);