Don't return video interface if real interface is missing. Closes #3735

This commit is contained in:
baldurk
2025-11-27 15:20:36 +00:00
parent c61e3f72f0
commit f5e9903860
+11 -3
View File
@@ -51,9 +51,17 @@ HRESULT STDMETHODCALLTYPE WrappedID3D11VideoDevice2::QueryInterface(REFIID riid,
}
else if(riid == __uuidof(ID3D11VideoDevice))
{
*ppvObject = (ID3D11VideoDevice *)this;
AddRef();
return S_OK;
if(m_pReal)
{
*ppvObject = (ID3D11VideoDevice *)this;
AddRef();
return S_OK;
}
else
{
*ppvObject = NULL;
return E_NOINTERFACE;
}
}
else if(riid == __uuidof(ID3D11VideoDevice1))
{