Open Mivik opened 1 year ago
I don't currently have a dev environment for compiling Rust code for Android. I can work on setting one up, but in the meantime, can you get a stacktrace for that panic?
I don't currently have a dev environment for compiling Rust code for Android. I can work on setting one up, but in the meantime, can you get a stacktrace for that panic?
For some reason I was unable to get a concrete stacktrace. I debugged the program and here's roughly the call stack:
oboe::AudioStream::fireDataCallback
(oboe/src/common/AudioStream.cpp:63)StreamManager audio output stream callback
https://github.com/tesselode/kira/blob/dc66cd995c5b522ba68f20a305bc43f4e6ab718d/crates/kira/src/manager/backend/cpal/desktop/stream_manager.rs#L130RendererWrapper deref()
https://github.com/tesselode/kira/blob/dc66cd995c5b522ba68f20a305bc43f4e6ab718d/crates/kira/src/manager/backend/cpal/desktop/stream_manager/renderer_wrapper.rs#L34Here the renderer is already taken by drop and thus the program panics.
@Mivik it seems like cpal is using Kira's stream manager after dropping it, which would be a bug in cpal. I'd open an issue in their repo and see what they say.
The minimal reproducing steps are simply dropping a
AudioManager
.Currently this issue is temporarily fixed by implementing the Drop trait for the oboe backend of cpal (host/oboe/mod.rs):
Not sure if this is an issue of cpal.