1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2025-03-13 19:29:14 +01:00

[d3d9] Fix crash when calling ColorFill with NULL format

Impacts #1528
This commit is contained in:
Joshua Ashton 2020-03-25 07:23:17 +00:00
parent bb0772eb8d
commit bb2e88ee06

View File

@ -1066,8 +1066,13 @@ namespace dxvk {
cClearValue);
});
} else {
if (unlikely(rtView == nullptr))
Logger::err(str::format("D3D9DeviceEx::ColorFill: Unsupported format ", dstTextureInfo->Desc()->Format));
if (unlikely(rtView == nullptr)) {
const D3D9Format format = dstTextureInfo->Desc()->Format;
if (format != D3D9Format::NULL_FORMAT)
Logger::err(str::format("D3D9DeviceEx::ColorFill: Unsupported format ", format));
return D3D_OK;
}
EmitCs([
cImageView = rtView,