msdmo: Avoid leaking key handles in DMOGetTypes().

Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2020-07-13 09:38:04 -05:00 committed by Alexandre Julliard
parent 37b926b8fe
commit 78d2a0919e
1 changed files with 2 additions and 0 deletions

View File

@ -741,5 +741,7 @@ HRESULT WINAPI DMOGetTypes(REFCLSID clsid, ULONG input_count, ULONG *ret_input_c
if (!ret || ret == ERROR_MORE_DATA) if (!ret || ret == ERROR_MORE_DATA)
*ret_output_count = min(output_count, size / sizeof(DMO_PARTIAL_MEDIATYPE)); *ret_output_count = min(output_count, size / sizeof(DMO_PARTIAL_MEDIATYPE));
RegCloseKey(key);
RegCloseKey(root);
return S_OK; return S_OK;
} }