[ALSA] Fix playback and capture on ALSA.

This commit is contained in:
David Reid
2017-10-28 16:35:38 +10:00
parent cd63a62563
commit e895f4add2
+1 -1
View File
@@ -4644,7 +4644,7 @@ static mal_uint32 mal_device__wait_for_frames__alsa(mal_device* pDevice)
static mal_bool32 mal_device_write__alsa(mal_device* pDevice) static mal_bool32 mal_device_write__alsa(mal_device* pDevice)
{ {
mal_assert(pDevice != NULL); mal_assert(pDevice != NULL);
if (!mal_device_is_started(pDevice)) { if (!mal_device_is_started(pDevice) && mal_device__get_state(pDevice) != MAL_STATE_STARTING) {
return MAL_FALSE; return MAL_FALSE;
} }
if (pDevice->alsa.breakFromMainLoop) { if (pDevice->alsa.breakFromMainLoop) {