d3dx9: WARN when the file doesn't exist in D3DXCreateTextureFromFileExW().

Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Matteo Bruni 2019-09-30 23:11:12 +02:00 committed by Alexandre Julliard
parent ceabad19b8
commit 81ababa864
1 changed files with 3 additions and 0 deletions

View File

@ -773,7 +773,10 @@ HRESULT WINAPI D3DXCreateTextureFromFileExW(struct IDirect3DDevice9 *device, con
hr = map_view_of_file(srcfile, &buffer, &size); hr = map_view_of_file(srcfile, &buffer, &size);
if (FAILED(hr)) if (FAILED(hr))
{
WARN("Failed to open file.\n");
return D3DXERR_INVALIDDATA; return D3DXERR_INVALIDDATA;
}
hr = D3DXCreateTextureFromFileInMemoryEx(device, buffer, size, width, height, miplevels, usage, format, pool, hr = D3DXCreateTextureFromFileInMemoryEx(device, buffer, size, width, height, miplevels, usage, format, pool,
filter, mipfilter, colorkey, srcinfo, palette, texture); filter, mipfilter, colorkey, srcinfo, palette, texture);