Commit 7771a49e authored by Rafaël Carré's avatar Rafaël Carré

directsound: fix crash when no audio card is present on the system

parent e35f2085
...@@ -384,6 +384,7 @@ static void Stop( audio_output_t *p_aout ) ...@@ -384,6 +384,7 @@ static void Stop( audio_output_t *p_aout )
IDirectSoundNotify_Release(p_sys->p_notify ); IDirectSoundNotify_Release(p_sys->p_notify );
p_sys->p_notify = NULL; p_sys->p_notify = NULL;
if( p_sys->p_dsbuffer )
IDirectSoundBuffer_Stop( p_sys->p_dsbuffer ); IDirectSoundBuffer_Stop( p_sys->p_dsbuffer );
/* release the secondary buffer */ /* release the secondary buffer */
DestroyDSBuffer( p_aout ); DestroyDSBuffer( p_aout );
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment