vkd3d-shader/ir: Validate index count for DEPTHOUTLE registers.

This commit is contained in:
Giovanni Mascellani 2024-09-26 21:27:31 +02:00 committed by Henri Verbeet
parent 6259832680
commit 19d35d89cd
Notes: Henri Verbeet 2024-10-02 22:38:04 +02:00
Approved-by: Elizabeth Figura (@zfigura)
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Henri Verbeet (@hverbeet)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/1136

View File

@ -6237,6 +6237,13 @@ static void vsir_validate_register(struct validation_context *ctx,
reg->idx_count);
break;
case VKD3DSPR_DEPTHOUTLE:
if (reg->idx_count != 0)
validator_error(ctx, VKD3D_SHADER_ERROR_VSIR_INVALID_INDEX_COUNT,
"Invalid index count %u for a DEPTHOUTLE register.",
reg->idx_count);
break;
default:
break;
}