# HG changeset patch # User Sam Lantinga # Date 1007601622 0 # Node ID 8e47ebb7bced6e47316e79992d3952ab4253be70 # Parent b0f09f86378de84b8576f548e92d889728f1e87e Reset the device before closing it - fixes a hang with some audio drivers diff -r b0f09f86378d -r 8e47ebb7bced src/audio/dsp/SDL_dspaudio.c --- a/src/audio/dsp/SDL_dspaudio.c Wed Dec 05 23:49:09 2001 +0000 +++ b/src/audio/dsp/SDL_dspaudio.c Thu Dec 06 01:20:22 2001 +0000 @@ -233,6 +233,8 @@ mixbuf = NULL; } if ( audio_fd >= 0 ) { + int value; + ioctl(audio_fd, SNDCTL_DSP_RESET, &value); close(audio_fd); audio_fd = -1; }