# getUserData android crash

**URL:** <https://qa.fmod.com/t/getuserdata-android-crash/21139>\
**Category:** FMOD Engine\
**Created:** [January 22, 2024, 1:44pm UTC](https://qa.fmod.com/t/getuserdata-android-crash/21139 "2024-01-22T13:44:18Z")\
**Posts on this page:** 1\
**Showing post:** 9

<div class="post-metadata">

**Author:** ![maksimomelyanchuk](https://avatars.discourse-cdn.com/v4/letter/m/eb8c5e/32.png) [@maksimomelyanchuk](https://qa.fmod.com/u/maksimomelyanchuk)\
**Post date:** [April 3, 2024, 4:57am UTC](https://qa.fmod.com/t/getuserdata-android-crash/21139/9 "2024-04-03T04:57:21Z")

</div>

We did some research, so I want to share the results with you. I hope it will help you investigate the problem.  
The previous callstack seems to be wrong. The correct one looks like this:

```auto
#0: libfmod.so+0xd73e8 // seems to be OutputRingBuffer::read( 0xb400007155bca800, 0x0, 0x240, true)
#1: libfmod.so+0xe8df8 // seems to be OutputOpenSL::feederThread
#2: libwilhelm.so`audioTrack_handleMoreData_lockPlay(CAudioPlayer_struct*, android::AudioTrack::Buffer const&) + 136
#3: libwilhelm.so`android::AudioTrackCallback::onMoreData(android::AudioTrack::Buffer const&) + 52
#4: libaudioclient.so`android::AudioTrack::processAudioBuffer() + 3048
#5: libaudioclient.so`android::AudioTrack::AudioTrackThread::threadLoop() + 300
#6: libutils.so`android::Thread::_threadLoop(void*) + 428
#7: libandroid_runtime.so`android::AndroidRuntime::javaThreadShell(void*) + 148
#8: libc.so`__pthread_start(void*) + 212
#9: libc.so`__start_thread + 72

```

Recently, we made a change in our code. Now, we call `_lowLevelSystem->setOutput(FMOD_OUTPUTTYPE_NOSOUND)` when the application goes on pause, and `_lowLevelSystem->setOutput(FMOD_OUTPUTTYPE_OPENSL)` when the application resumes. After this change, this occurs more often. As I mentioned before, it seems that the crash occurs after losing the audio context, suggesting a connection between these two things.

---

_[View the full topic](https://qa.fmod.com/t/getuserdata-android-crash/21139)._
