mirror of
https://github.com/mauiaaron/apple2.git
synced 2025-01-13 12:31:25 +00:00
Remove aggressive assert that fired on Cyanogen device (even with a valid CPU pause/resume lifecycle) ...
This commit is contained in:
parent
abe1346051
commit
9fd288c0b9
@ -741,20 +741,17 @@ static long opensles_systemResume(AudioContext_s *audio_context) {
|
||||
break;
|
||||
}
|
||||
|
||||
#if !TESTING
|
||||
assert(state != SL_PLAYSTATE_PLAYING && "mismatch between systemPause/systemResume");
|
||||
#endif
|
||||
if (state != SL_PLAYSTATE_PLAYING) {
|
||||
ERRLOG("WARNING: possible audio lifecycle mismatch ... continuing anyway");
|
||||
}
|
||||
|
||||
if (state == SL_PLAYSTATE_PAUSED) {
|
||||
// Balanced resume OK here
|
||||
SLresult result = (*(ctx->bqPlayerPlay))->SetPlayState(ctx->bqPlayerPlay, SL_PLAYSTATE_PLAYING);
|
||||
#if !TESTING
|
||||
} else {
|
||||
} else if (state == SL_PLAYSTATE_STOPPED) {
|
||||
// Do not resume for stopped state, let this get forced from CPU/speaker thread otherwise we starve. (The
|
||||
// stopped state happens if user dynamically changed buffer parameters in menu settings which triggered an
|
||||
// OpenSLES destroy/re-initialization ... e.g. audio_setLatency() was invoked)
|
||||
assert(state == SL_PLAYSTATE_STOPPED);
|
||||
#endif
|
||||
}
|
||||
} while (0);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user