1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-11 23:54:18 +00:00

Android: Fixed a race condition when switching the buffer size on the Android OpenSL audio device

This commit is contained in:
hogliux 2017-08-23 18:22:17 +01:00
parent 0e95d97404
commit ac5797da58

View file

@ -651,11 +651,16 @@ public:
{
OpenSLSession::stop();
while (! guard.compareAndSetBool (1, 0))
Thread::sleep (1);
if (inputChannels > 0)
recorder->setState (false);
if (outputChannels > 0)
player->setState (false);
guard.set (0);
}
bool setAudioPreprocessingEnabled (bool shouldEnable) override