Commit b5f7ce42 authored by Rémi Bernon's avatar Rémi Bernon Committed by Alexandre Julliard

mfreadwrite/reader: Make the GetTransformForStream category parameter optional.

parent 17fd8c8e
......@@ -2512,6 +2512,9 @@ static HRESULT WINAPI src_reader_GetTransformForStream(IMFSourceReaderEx *iface,
TRACE("%p, %#lx, %#lx, %p, %p.\n", iface, stream_index, transform_index, category, transform);
if (!transform)
return E_POINTER;
EnterCriticalSection(&reader->cs);
if (stream_index == MF_SOURCE_READER_FIRST_VIDEO_STREAM)
......@@ -2525,7 +2528,8 @@ static HRESULT WINAPI src_reader_GetTransformForStream(IMFSourceReaderEx *iface,
hr = MF_E_INVALIDINDEX;
else
{
*category = entry->category;
if (category)
*category = entry->category;
*transform = entry->transform;
IMFTransform_AddRef(*transform);
hr = S_OK;
......
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