quartz/filesource: Correctly initialize the default media type.

Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2019-02-21 18:42:57 -06:00 committed by Alexandre Julliard
parent 397c15ab77
commit a67ad09528
2 changed files with 2 additions and 4 deletions

View File

@ -623,8 +623,8 @@ static HRESULT WINAPI FileSource_Load(IFileSourceFilter * iface, LPCOLESTR pszFi
This->pmt->cbFormat = 0; This->pmt->cbFormat = 0;
This->pmt->pbFormat = NULL; This->pmt->pbFormat = NULL;
This->pmt->pUnk = NULL; This->pmt->pUnk = NULL;
This->pmt->lSampleSize = 0; This->pmt->lSampleSize = 1;
This->pmt->formattype = FORMAT_None; This->pmt->formattype = GUID_NULL;
hr = GetClassMediaFile(pReader, pszFileName, &This->pmt->majortype, &This->pmt->subtype, NULL); hr = GetClassMediaFile(pReader, pszFileName, &This->pmt->majortype, &This->pmt->subtype, NULL);
if (FAILED(hr)) if (FAILED(hr))
{ {

View File

@ -237,11 +237,9 @@ static void test_file_source_filter(void)
ok(file_mt.bFixedSizeSamples == TRUE, "Got fixed size %d.\n", file_mt.bFixedSizeSamples); ok(file_mt.bFixedSizeSamples == TRUE, "Got fixed size %d.\n", file_mt.bFixedSizeSamples);
ok(file_mt.bTemporalCompression == FALSE, "Got temporal compression %d.\n", ok(file_mt.bTemporalCompression == FALSE, "Got temporal compression %d.\n",
file_mt.bTemporalCompression); file_mt.bTemporalCompression);
todo_wine {
ok(file_mt.lSampleSize == 1, "Got sample size %u.\n", file_mt.lSampleSize); ok(file_mt.lSampleSize == 1, "Got sample size %u.\n", file_mt.lSampleSize);
ok(IsEqualGUID(&file_mt.formattype, &GUID_NULL), "Got format type %s.\n", ok(IsEqualGUID(&file_mt.formattype, &GUID_NULL), "Got format type %s.\n",
wine_dbgstr_guid(&file_mt.formattype)); wine_dbgstr_guid(&file_mt.formattype));
}
ok(!file_mt.pUnk, "Got pUnk %p.\n", file_mt.pUnk); ok(!file_mt.pUnk, "Got pUnk %p.\n", file_mt.pUnk);
ok(!file_mt.cbFormat, "Got format size %#x.\n", file_mt.cbFormat); ok(!file_mt.cbFormat, "Got format size %#x.\n", file_mt.cbFormat);
ok(!file_mt.pbFormat, "Got format %p.\n", file_mt.pbFormat); ok(!file_mt.pbFormat, "Got format %p.\n", file_mt.pbFormat);