d3d9: Translate E_INVALIDARG to D3DERR_INVALIDCALL in d3d9_surface_LockRect().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
471715b946
commit
6b86019a96
|
@ -258,6 +258,8 @@ static HRESULT WINAPI d3d9_surface_LockRect(IDirect3DSurface9 *iface,
|
||||||
locked_rect->pBits = map_desc.data;
|
locked_rect->pBits = map_desc.data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (hr == E_INVALIDARG)
|
||||||
|
return D3DERR_INVALIDCALL;
|
||||||
return hr;
|
return hr;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -12103,7 +12103,6 @@ static void test_lockable_backbuffer(void)
|
||||||
ok(SUCCEEDED(hr), "Failed to get backbuffer, hr %#x.\n", hr);
|
ok(SUCCEEDED(hr), "Failed to get backbuffer, hr %#x.\n", hr);
|
||||||
|
|
||||||
hr = IDirect3DSurface9_LockRect(surface, &lockrect, NULL, D3DLOCK_DISCARD);
|
hr = IDirect3DSurface9_LockRect(surface, &lockrect, NULL, D3DLOCK_DISCARD);
|
||||||
todo_wine
|
|
||||||
ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr);
|
ok(hr == D3DERR_INVALIDCALL, "Got unexpected hr %#x.\n", hr);
|
||||||
|
|
||||||
dc = (void *)0xdeadbeef;
|
dc = (void *)0xdeadbeef;
|
||||||
|
|
Loading…
Reference in New Issue