[vlc-devel] [PATCH] mmdevice: don't hard crash when CoInitializeEx fails on Start, show the reason

Rémi Denis-Courmont remi at remlab.net
Wed Mar 18 10:11:48 CET 2015


Looks wrong to me.

Le 2015-03-18 11:53, Steve Lhomme a écrit :
> ---
>  modules/audio_output/mmdevice.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/modules/audio_output/mmdevice.c
> b/modules/audio_output/mmdevice.c
> index d9d3573..3df2686 100644
> --- a/modules/audio_output/mmdevice.c
> +++ b/modules/audio_output/mmdevice.c
> @@ -1079,7 +1079,8 @@ static int Start(audio_output_t *aout,
> audio_sample_format_t *restrict fmt)
>      s->owner.device = sys->dev;
>      s->owner.activate = ActivateDevice;
>
> -    EnterMTA();
> +    if( TryEnterMTA( aout ) )
> +        return -1;
>      for (;;)
>      {
>          HRESULT hr;

-- 
Rémi Denis-Courmont



More information about the vlc-devel mailing list