oboe: Significant number of crash reports from Oboe library

Android version(s): 9 and 10 but 90% from Android 10 Android device(s): Assortment of devices Oboe version: 1.5.0 App name used for testing: M64Plus FZ

Short description Library causes a crash when calling requestStart or start

Steps to reproduce N/A

Expected behavior It doesn’t crash

Actual behavior Random crashing

Device Assortment of devices

Any additional context I’m getting various core dumps through crashlytics, here are a couple:

Crashed: Thread :  SIGSEGV  0x000067fd3612f1c0
#00 pc 0x75f01a5774 libaaudio.so 
#01 pc 0x757b09bc30 liboboe.so (oboe::AudioStreamAAudio::requestStart() [AudioStreamAAudio.cpp:382])
#02 pc 0x757b09bc30 liboboe.so (oboe::AudioStreamAAudio::requestStart() [AudioStreamAAudio.cpp:382])
#03 pc 0x757b09d05c liboboe.so (oboe::AudioStream::start(long) [AudioStream.cpp:107])
#04 pc 0x757b0e8098 libmupen64plus-audio-android.so (AudioHandler::resumePlayback() [AudioHandler.cpp:558])
#05 pc 0x757f2d1e70 libjnidispatch.so 
Crashed: Thread :  SIGSEGV  0x0000000000110074
#00 pc 0xdf05a672 libaaudio.so 
#01 pc 0xbb4dc41f liboboe.so (oboe::AudioStreamAAudio::requestStart() [AudioStreamAAudio.cpp:382])
#02 pc 0xbb4dd30b liboboe.so (oboe::AudioStream::start(long long) [AudioStream.cpp:107])
#03 pc 0xbb5638ed libmupen64plus-audio-android.so (AudioHandler::resumePlayback() [AudioHandler.cpp:558])
#04 pc 0xbebe6ce2 libjnidispatch.so 
#05 pc 0xbb5628ff libmupen64plus-audio-android.so (pauseEmulator [plugin.cpp:494])

Only the top most part of the back trace is included.

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 1
  • Comments: 27

Most upvoted comments

Thanks for the update. We should warn against declaring the stream variable in a method. I added that to:

https://github.com/google/oboe/blob/master/docs/GettingStarted.md#creating-an-audio-stream

I’m currently using this type for my stream: ManagedStream

We have found potential race conditions associated with using ManagedStream or using the raw stream pointer. Those are now deprecated. It could cause these kinds of crashes.

Please use std::shared_ptr. I think that will fix it. If not then please open a new bug.

(I just noticed the GettingStarted guide still references ManagedStream!)

By the way, you have this commented out:

//builder.setSampleRateConversionQuality(oboe::SampleRateConversionQuality::Fastest);

You can get significantly lower latency for other sample rates if you enable it and use Medium quality:

builder.setSampleRateConversionQuality(oboe::SampleRateConversionQuality::**Medium**);