Hey, I have a tough one to find and debug but I'm pretty sure it's real. I create a lot of audio streams using callbacks and upon finishing, I call SDL_UnbindAudioStream and sometimes later SDL_DestroyAudioStream. For bookkeeping I use Lock/UnlockAudioStream. Now sometimes, after SDL_UnbindAudioStream and before SDL_DestroyAudioStream, a call to SDL_LockAudioStream will never return. My app is single-threaded so the only thing running on another thread is the callback I guess. I am ready to answer any kind of questions, I double-checked my code but there could be issues of course, I also checked audiocvt.c and saw the "mutex nighmare" comments however the issue here is that it happens at a later point... If I don't call SDL_UnbindAudioStream everything is OK.
Hey, I have a tough one to find and debug but I'm pretty sure it's real. I create a lot of audio streams using callbacks and upon finishing, I call
SDL_UnbindAudioStreamand sometimes laterSDL_DestroyAudioStream. For bookkeeping I use Lock/UnlockAudioStream. Now sometimes, afterSDL_UnbindAudioStreamand beforeSDL_DestroyAudioStream, a call toSDL_LockAudioStreamwill never return. My app is single-threaded so the only thing running on another thread is the callback I guess. I am ready to answer any kind of questions, I double-checked my code but there could be issues of course, I also checked audiocvt.c and saw the "mutex nighmare" comments however the issue here is that it happens at a later point... If I don't callSDL_UnbindAudioStreameverything is OK.