dxgi: Return DXGI_ERROR_INVALID_CALL when given a NULL mode_count in dxgi_output_GetDisplayModeList().
This commit is contained in:
parent
4d7bd4ce4a
commit
d9570c3935
|
@ -132,9 +132,7 @@ static HRESULT STDMETHODCALLTYPE dxgi_output_GetDisplayModeList(IDXGIOutput *ifa
|
|||
iface, debug_dxgi_format(format), flags, mode_count, desc);
|
||||
|
||||
if (!mode_count)
|
||||
{
|
||||
return S_OK;
|
||||
}
|
||||
return DXGI_ERROR_INVALID_CALL;
|
||||
|
||||
if (format == DXGI_FORMAT_UNKNOWN)
|
||||
{
|
||||
|
|
|
@ -279,7 +279,7 @@ static void test_output(void)
|
|||
ok(SUCCEEDED(hr), "EnumOutputs failed, hr %#x.\n", hr);
|
||||
|
||||
hr = IDXGIOutput_GetDisplayModeList(output, DXGI_FORMAT_R8G8B8A8_UNORM, 0, NULL, NULL);
|
||||
todo_wine ok(hr == DXGI_ERROR_INVALID_CALL, "Got unexpected hr %#x.\n", hr);
|
||||
ok(hr == DXGI_ERROR_INVALID_CALL, "Got unexpected hr %#x.\n", hr);
|
||||
|
||||
hr = IDXGIOutput_GetDisplayModeList(output, DXGI_FORMAT_R8G8B8A8_UNORM, 0, &mode_count, NULL);
|
||||
ok(SUCCEEDED(hr)
|
||||
|
@ -309,7 +309,7 @@ static void test_output(void)
|
|||
|
||||
hr = IDXGIOutput_GetDisplayModeList(output, DXGI_FORMAT_R8G8B8A8_UNORM,
|
||||
DXGI_ENUM_MODES_SCALING, NULL, modes);
|
||||
todo_wine ok(hr == DXGI_ERROR_INVALID_CALL, "Got unexpected hr %#x.\n", hr);
|
||||
ok(hr == DXGI_ERROR_INVALID_CALL, "Got unexpected hr %#x.\n", hr);
|
||||
ok(!modes[0].Height, "No output was expected.\n");
|
||||
|
||||
mode_count = 0;
|
||||
|
|
Loading…
Reference in New Issue