dmime: Add Release() on some codepaths.

Signed-off-by: Eric Pouech <epouech@codeweavers.com>
This commit is contained in:
Eric Pouech 2023-11-27 18:05:02 +01:00 committed by Alexandre Julliard
parent b138be092e
commit 6343dc6c95

View file

@ -373,7 +373,10 @@ static HRESULT WINAPI segment_GetParam(IDirectMusicSegment8 *iface, REFGUID type
for (i = 0, count = 0; i < DMUS_SEG_ANYTRACK && count <= index; i++) {
if (FAILED(segment_GetTrack(iface, &GUID_NULL, group, i, &track))) break;
if (FAILED(IDirectMusicTrack_IsParamSupported(track, type)))
{
IDirectMusicTrack_Release(track);
continue;
}
if (index == count || index == DMUS_SEG_ANYTRACK)
hr = IDirectMusicTrack_GetParam(track, type, time, next, param);
IDirectMusicTrack_Release(track);