mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-14 02:07:49 +00:00
Removed redundant wait at shutdown in the ALSA audio driver
(cherry picked from commit 97e2951875)
This commit is contained in:
parent
1fd4703907
commit
4ae517e24e
1 changed files with 0 additions and 6 deletions
|
|
@ -461,12 +461,6 @@ static void ALSA_CloseDevice(SDL_AudioDevice *device)
|
|||
{
|
||||
if (device->hidden) {
|
||||
if (device->hidden->pcm) {
|
||||
// Wait for the submitted audio to drain. ALSA_snd_pcm_drop() can hang, so don't use that.
|
||||
int delay = ((device->sample_frames * 1000) / device->spec.freq) * 2;
|
||||
if (delay > 100) {
|
||||
delay = 100;
|
||||
}
|
||||
SDL_Delay(delay);
|
||||
ALSA_snd_pcm_close(device->hidden->pcm);
|
||||
}
|
||||
SDL_free(device->hidden->mixbuf);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue