mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d-shader/dxil: Return an error from sm6_parser_globals_init() on invalid operand count.
This commit is contained in:
parent
e0e261eac3
commit
8fe6d2eeac
Notes:
Alexandre Julliard
2023-07-20 22:57:52 +02:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Henri Verbeet (@hverbeet) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/278
@ -1767,7 +1767,8 @@ static enum vkd3d_result sm6_parser_globals_init(struct sm6_parser *sm6)
|
||||
break;
|
||||
|
||||
case MODULE_CODE_VERSION:
|
||||
dxil_record_validate_operand_count(record, 1, 1, sm6);
|
||||
if (!dxil_record_validate_operand_count(record, 1, 1, sm6))
|
||||
return VKD3D_ERROR_INVALID_SHADER;
|
||||
if ((version = record->operands[0]) != 1)
|
||||
{
|
||||
FIXME("Unsupported format version %#"PRIx64".\n", version);
|
||||
|
Loading…
Reference in New Issue
Block a user