Any shader that would underflow is invalid, but it is helpful to allow tracing even invalid shaders.
From: Zebediah Figura zfigura@codeweavers.com
Any shader that would underflow is invalid, but it is helpful to allow tracing even invalid shaders. --- libs/vkd3d-shader/trace.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/libs/vkd3d-shader/trace.c b/libs/vkd3d-shader/trace.c index 8e2cac16..f32f26a7 100644 --- a/libs/vkd3d-shader/trace.c +++ b/libs/vkd3d-shader/trace.c @@ -1930,7 +1930,8 @@ enum vkd3d_result vkd3d_dxbc_binary_to_text(struct vkd3d_shader_parser *parser, case VKD3DSIH_ENDIF: case VKD3DSIH_ENDLOOP: case VKD3DSIH_ENDSWITCH: - --indent; + if (indent) + --indent; break;
default:
This merge request was approved by Giovanni Mascellani.
This merge request was approved by Henri Verbeet.