vkd3d-shader/hlsl: Fix typo (Coverity).

I assume this is a typo, right now it doesn't make sense.

Signed-off-by: Fabian Maurer <dark.shadow4@web.de>
This commit is contained in:
Fabian Maurer 2022-12-11 19:53:24 +01:00 committed by Alexandre Julliard
parent 5b1030e0cb
commit 9519fcb562
Notes: Alexandre Julliard 2023-01-11 22:39:12 +01:00
Approved-by: Giovanni Mascellani (@giomasce)
Approved-by: Zebediah Figura (@zfigura)
Approved-by: Francisco Casas (@fcasas)
Approved-by: Henri Verbeet (@hverbeet)
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/56

View File

@ -3140,7 +3140,7 @@ static bool add_method_call(struct hlsl_ctx *ctx, struct list *instrs, struct hl
if (!strcmp(name, "Gather") || !offset_dim)
{
if (params->args_count < 2 && params->args_count > 3 + !!offset_dim)
if (params->args_count < 2 || params->args_count > 3 + !!offset_dim)
{
hlsl_error(ctx, loc, VKD3D_SHADER_ERROR_HLSL_WRONG_PARAMETER_COUNT,
"Wrong number of arguments to method '%s': expected from 2 to %u, but got %u.",