androidandroid-ndkandroid-native-library

Android - Debugging native crashes


I have application which uses native library, but also threading and various Bluetooth features. It mostly works fine, but at some unknown situation, the application crashes (it's really hard to reproduce it). Although, Android Studio / logcat gives me only this:

2021-07-20 13:17:45.179 22749-26157/sk.marekkraus.appie I/scudo: Scudo ERROR: corrupted chunk header at address 0x0075e162e990
2021-07-20 13:17:45.180 22749-26157/sk.marekkraus.appie A/libc: Fatal signal 6 (SIGABRT), code -1 (SI_QUEUE) in tid 26157 (RenderThread), pid 22749 (rekkraus.appie)

No backtraces, no crash dumps (tombstones). How to debug those crashes?


Solution

  • By default, Logcat window in Android Studio shows only selected application's logs. When app crash, the backtrace and other information are printed to logcat by other applications (which are handling those crashes), thus by default, you don't see those logs. For switching to full logcat of phone, you need select No filters in Logcat's window

    Switching to No filters