[D3D9Ex] Make sure the creation succeeded
This commit is contained in:
parent
47c8fcc644
commit
424c7e7adf
@ -733,8 +733,9 @@ namespace Components
|
|||||||
{
|
{
|
||||||
if (Dvar::Var("r_useD3D9Ex").get<bool>())
|
if (Dvar::Var("r_useD3D9Ex").get<bool>())
|
||||||
{
|
{
|
||||||
IDirect3D9Ex* test;
|
IDirect3D9Ex* test = nullptr;
|
||||||
Direct3DCreate9Ex(sdk, &test);
|
if (FAILED(Direct3DCreate9Ex(sdk, &test))) return nullptr;
|
||||||
|
|
||||||
return (new D3D9Ex::D3D9(test));
|
return (new D3D9Ex::D3D9(test));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
Loading…
Reference in New Issue
Block a user