1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-02-18 13:54:16 +01:00

[d3d11] Validate texture array size

Fixes a wine test failure and possibly prevents invalid Vulkan API usage.
This commit is contained in:
Philip Rebohle 2019-10-11 17:11:01 +02:00
parent 554b77b47a
commit 127e037627
No known key found for this signature in database
GPG Key ID: C8CC613427A31C99

View File

@ -274,7 +274,7 @@ namespace dxvk {
HRESULT D3D11CommonTexture::NormalizeTextureProperties(D3D11_COMMON_TEXTURE_DESC* pDesc) {
if (pDesc->Width == 0 || pDesc->Height == 0 || pDesc->Depth == 0)
if (pDesc->Width == 0 || pDesc->Height == 0 || pDesc->Depth == 0 || pDesc->ArraySize == 0)
return E_INVALIDARG;
if (FAILED(DecodeSampleCount(pDesc->SampleDesc.Count, nullptr)))