windowscodecs: Return E_INVALIDARG from GetFrame with NULL pointer.

Signed-off-by: Rémi Bernon <rbernon@codeweavers.com>
Signed-off-by: Esme Povirk <esme@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Rémi Bernon 2021-02-05 09:11:01 +01:00 committed by Alexandre Julliard
parent 958b433272
commit 8f1122f8d2
2 changed files with 2 additions and 2 deletions

View File

@ -724,7 +724,7 @@ static HRESULT WINAPI CommonDecoder_GetFrame(IWICBitmapDecoder *iface,
TRACE("(%p,%u,%p)\n", iface, index, ppIBitmapFrame);
if (!ppIBitmapFrame)
return E_POINTER;
return E_INVALIDARG;
EnterCriticalSection(&This->lock);

View File

@ -123,7 +123,7 @@ static void test_decode(void)
ok(count == 1, "unexpected count %u\n", count);
hr = IWICBitmapDecoder_GetFrame(decoder, 0, NULL);
todo_wine ok(hr == E_INVALIDARG, "GetFrame(NULL) returned hr=%x\n", hr);
ok(hr == E_INVALIDARG, "GetFrame(NULL) returned hr=%x\n", hr);
for (j = 2; j > 0; --j)
{