Crash on Android 12 when app is sent to background
PedroCitrix opened this issue · comments
Hi all,
I am trying to debug an issue where a customer's app crashes when sent to the background. The app works fine in Android 11 and below, but starting with Android 12 I see this entry which I hope to rule out as not the issue by posting here:
03-08 20:32:11.184 28444 28444 F DEBUG : #1 pc 0000000000021110 /apex/com.android.art/lib64/libperfetto_hprof.so (void std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_deletestd::__1::__thread_struct >, ArtPlugin_Initialize::$_33> >(void)+280) (BuildId: 3451c89ffa8cc7a37c7765bde07d2dd9)**
03-08 20:32:11.183 28444 28444 F DEBUG : ABI: 'arm64'
03-08 20:32:11.183 28444 28444 F DEBUG : Timestamp: 2022-03-08 20:32:10.044023636+0100
03-08 20:32:11.183 28444 28444 F DEBUG : Process uptime: 48s
03-08 20:32:11.183 28444 28444 F DEBUG : Cmdline: *****
03-08 20:32:11.183 28444 28444 F DEBUG : pid: 28198, tid: 28204, name: perfetto_hprof_ >>> *****<<<
03-08 20:32:11.183 28444 28444 F DEBUG : uid: 1010297
03-08 20:32:11.183 28444 28444 F DEBUG : signal 7 (SIGBUS), code 1 (BUS_ADRALN), fault addr 0x3f
03-08 20:32:11.183 28444 28444 F DEBUG : x0 0000000000000003 x1 0000007b53dc9c04 x2 0000000000000001 x3 0000007b53dc99e8
03-08 20:32:11.184 28444 28444 F DEBUG : x4 0000000000000008 x5 b400007b82e633b8 x6 0000007b71212c20 x7 0000007b71212c20
03-08 20:32:11.184 28444 28444 F DEBUG : x8 000000000000003f x9 6999b33021ca344f x10 0000000000000001 x11 0000000000000000
03-08 20:32:11.184 28444 28444 F DEBUG : x12 0000000000000011 x13 00000000e690f1c1 x14 0000007b70f69154 x15 0000007b70ad6220
03-08 20:32:11.184 28444 28444 F DEBUG : x16 0000007b659fb828 x17 0000007e6995d9f0 x18 0000007b4ec2a000 x19 b400007b82e600b0
03-08 20:32:11.184 28444 28444 F DEBUG : x20 b400007ce2e609a0 x21 0000007b659fce10 x22 0000007b659fc000 x23 0000007b53dca000
03-08 20:32:11.184 28444 28444 F DEBUG : x24 0000007b53dc9cb0 x25 0000007b53dc9cb0 x26 0000007b53dc9ff8 x27 00000000000fc000
03-08 20:32:11.184 28444 28444 F DEBUG : x28 0000007b53cd1000 x29 0000007b53dc9c10
03-08 20:32:11.184 28444 28444 F DEBUG : lr 0000007b65975114 sp 0000007b53dc9bf0 pc 000000000000003f pst 0000000060001000
03-08 20:32:11.184 28444 28444 F DEBUG : backtrace:
03-08 20:32:11.184 28444 28444 F DEBUG : #00 pc 000000000000003f <unknown>
03-08 20:32:11.184 28444 28444 F DEBUG : #01 pc 0000000000021110 /apex/com.android.art/lib64/libperfetto_hprof.so (void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, ArtPlugin_Initialize::$_33> >(void*)+280) (BuildId: 3451c89ffa8cc7a37c7765bde07d2dd9)
03-08 20:32:11.184 28444 28444 F DEBUG : #02 pc 00000000000b2fd0 /apex/com.android.runtime/lib64/bionic/libc.so!libc.so (__pthread_start(void*)+264) (BuildId: 17e1b0bf97783158157befc3962dfee4)
03-08 20:32:11.184 28444 28444 F DEBUG : #03 pc 0000000000052834 /apex/com.android.runtime/lib64/bionic/libc.so (__start_thread+64) (BuildId: 17e1b0bf97783158157befc3962dfee4)
Hi, we've observed similar crashed in the past when an APK obfuscator is in use. Sometimes APK obfuscators play tricks and try to change the .got and .plt, and this results in some libc calls in other threads failing.
Is your app using an APK obfuscator?
It would be great if you could share more details. Which device is this? Is this an app publicly available on the Play Store? Which app is this?
Do you have a consistent way to reproduce this crash?
I can't say for sure if the stack trace you posted is related to the app crashing when sent to the background.