iOS: Only mark interrupted audio devices as non-interrupted if AudioQueueStart is successful.
diff --git a/src/audio/coreaudio/SDL_coreaudio.m b/src/audio/coreaudio/SDL_coreaudio.m
index 485d86d..32b9d9b 100644
--- a/src/audio/coreaudio/SDL_coreaudio.m
+++ b/src/audio/coreaudio/SDL_coreaudio.m
@@ -285,9 +285,9 @@ static void interruption_begin(_THIS)
static void interruption_end(_THIS)
{
if (this != NULL && this->hidden != NULL && this->hidden->audioQueue != NULL
- && this->hidden->interrupted) {
+ && this->hidden->interrupted
+ && AudioQueueStart(this->hidden->audioQueue, NULL) == AVAudioSessionErrorCodeNone) {
this->hidden->interrupted = SDL_FALSE;
- AudioQueueStart(this->hidden->audioQueue, NULL);
}
}