Skip to content

Commit

Permalink
sokol-audio wasapi: change assert check into an if when there's no da…
Browse files Browse the repository at this point in the history
…ta to submit
  • Loading branch information
floooh committed Sep 24, 2018
1 parent 5e6126b commit 1546dac
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions sokol_audio.h
Original file line number Diff line number Diff line change
Expand Up @@ -721,8 +721,9 @@ _SOKOL_PRIVATE DWORD _saudio_wasapi_thread_fn(LPVOID param) {
}
SOKOL_ASSERT(_saudio_wasapi.thread.dst_buffer_frames >= (int)padding);
UINT32 num_frames = _saudio_wasapi.thread.dst_buffer_frames - padding;
SOKOL_ASSERT(num_frames > 0);
_saudio_wasapi_submit_buffer(num_frames);
if (num_frames > 0) {
_saudio_wasapi_submit_buffer(num_frames);
}
}
return 0;
}
Expand Down

0 comments on commit 1546dac

Please sign in to comment.