mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-04-25 14:25:38 +00:00
Merge pull request #1378 from Areloch/PVS_Cleanup_595
Properly testing pointer vars aren't null before using them.
This commit is contained in:
commit
b54f41e36d
9 changed files with 56 additions and 49 deletions
|
|
@ -66,7 +66,7 @@ void GFXPCD3D9Device::createDirect3D9(LPDIRECT3D9 &d3d9, LPDIRECT3D9EX &d3d9ex)
|
|||
|
||||
if (pfnCreate9Ex)
|
||||
{
|
||||
if (!FAILED(pfnCreate9Ex(D3D_SDK_VERSION, &d3d9ex)) && d3d9ex)
|
||||
if (d3d9ex && !FAILED(pfnCreate9Ex(D3D_SDK_VERSION, &d3d9ex)))
|
||||
d3d9ex->QueryInterface(__uuidof(IDirect3D9), reinterpret_cast<void **>(&d3d9));
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue