mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d-utils: Return an error from open_include() if a NULL ID3DInclude was passed to D3DPreprocess().
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
e1aea0a3af
commit
dc7fd3760d
@ -131,6 +131,9 @@ static int open_include(const char *filename, bool local, const char *parent_dat
|
|||||||
ID3DInclude *iface = context;
|
ID3DInclude *iface = context;
|
||||||
unsigned int size;
|
unsigned int size;
|
||||||
|
|
||||||
|
if (!iface)
|
||||||
|
return VKD3D_ERROR;
|
||||||
|
|
||||||
if (FAILED(ID3DInclude_Open(iface, local ? D3D_INCLUDE_LOCAL : D3D_INCLUDE_SYSTEM,
|
if (FAILED(ID3DInclude_Open(iface, local ? D3D_INCLUDE_LOCAL : D3D_INCLUDE_SYSTEM,
|
||||||
filename, parent_data, &code->code, &size)))
|
filename, parent_data, &code->code, &size)))
|
||||||
return VKD3D_ERROR;
|
return VKD3D_ERROR;
|
||||||
|
Loading…
Reference in New Issue
Block a user