Commit 838f6834 authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

quartz/memallocator: Return S_OK when clearing the media type.

parent f1c74923
...@@ -686,7 +686,7 @@ static HRESULT WINAPI StdMediaSample2_SetMediaType(IMediaSample2 * iface, AM_MED ...@@ -686,7 +686,7 @@ static HRESULT WINAPI StdMediaSample2_SetMediaType(IMediaSample2 * iface, AM_MED
This->props.pMediaType = NULL; This->props.pMediaType = NULL;
} }
if (!pMediaType) if (!pMediaType)
return S_FALSE; return S_OK;
if (!(This->props.pMediaType = CoTaskMemAlloc(sizeof(AM_MEDIA_TYPE)))) if (!(This->props.pMediaType = CoTaskMemAlloc(sizeof(AM_MEDIA_TYPE))))
return E_OUTOFMEMORY; return E_OUTOFMEMORY;
......
...@@ -487,7 +487,7 @@ static void test_sample_properties(void) ...@@ -487,7 +487,7 @@ static void test_sample_properties(void)
ok(!mt, "Got media type %p.\n", mt); ok(!mt, "Got media type %p.\n", mt);
hr = IMediaSample_SetMediaType(sample, NULL); hr = IMediaSample_SetMediaType(sample, NULL);
todo_wine ok(hr == S_OK, "Got hr %#x.\n", hr); ok(hr == S_OK, "Got hr %#x.\n", hr);
mt = (AM_MEDIA_TYPE *)0xdeadbeef; mt = (AM_MEDIA_TYPE *)0xdeadbeef;
hr = IMediaSample_GetMediaType(sample, &mt); hr = IMediaSample_GetMediaType(sample, &mt);
...@@ -513,7 +513,7 @@ static void test_sample_properties(void) ...@@ -513,7 +513,7 @@ static void test_sample_properties(void)
ok(!memcmp(props.pMediaType, &expect_mt, sizeof(AM_MEDIA_TYPE)), "Media types didn't match.\n"); ok(!memcmp(props.pMediaType, &expect_mt, sizeof(AM_MEDIA_TYPE)), "Media types didn't match.\n");
hr = IMediaSample_SetMediaType(sample, NULL); hr = IMediaSample_SetMediaType(sample, NULL);
todo_wine ok(hr == S_OK, "Got hr %#x.\n", hr); ok(hr == S_OK, "Got hr %#x.\n", hr);
mt = (AM_MEDIA_TYPE *)0xdeadbeef; mt = (AM_MEDIA_TYPE *)0xdeadbeef;
hr = IMediaSample_GetMediaType(sample, &mt); hr = IMediaSample_GetMediaType(sample, &mt);
......
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