Commit d77f17f1 authored by Rémi Duraffort's avatar Rémi Duraffort

Add missing CoUninitialize.

For each CoInitialize we have to call CoUninitialize.
(cherry picked from commit ac1c62c8)
Signed-off-by: default avatarRémi Duraffort <ivoire@videolan.org>
parent b415326d
......@@ -2021,6 +2021,7 @@ static int ConfigDevicesCallback( vlc_object_t *p_this, char const *psz_name,
if( !p_item )
{
free( psz_device );
CoUninitialize();
return VLC_SUCCESS;
}
......@@ -2039,7 +2040,11 @@ static int ConfigDevicesCallback( vlc_object_t *p_this, char const *psz_name,
/* Enumerate devices */
FindCaptureDevice( p_this, NULL, &list_devices, b_audio );
if( !list_devices.size() ) return VLC_EGENERIC;
if( !list_devices.size() )
{
CoUninitialize();
return VLC_EGENERIC;
}
devicename = *list_devices.begin();
}
......
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