[vlc-commits] directsound: fix crash when no audio card is present on the system
Rafaël Carré
git at videolan.org
Wed Sep 4 18:15:03 CEST 2013
vlc | branch: master | Rafaël Carré <funman at videolan.org> | Wed Sep 4 18:14:30 2013 +0200| [7771a49e7261e9077c9aecb458293982a3607ca1] | committer: Rafaël Carré
directsound: fix crash when no audio card is present on the system
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=7771a49e7261e9077c9aecb458293982a3607ca1
---
modules/audio_output/directx.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/modules/audio_output/directx.c b/modules/audio_output/directx.c
index 48f3251..1bb719b 100644
--- a/modules/audio_output/directx.c
+++ b/modules/audio_output/directx.c
@@ -384,7 +384,8 @@ static void Stop( audio_output_t *p_aout )
IDirectSoundNotify_Release(p_sys->p_notify );
p_sys->p_notify = NULL;
- IDirectSoundBuffer_Stop( p_sys->p_dsbuffer );
+ if( p_sys->p_dsbuffer )
+ IDirectSoundBuffer_Stop( p_sys->p_dsbuffer );
/* release the secondary buffer */
DestroyDSBuffer( p_aout );
More information about the vlc-commits
mailing list