From 0dbbf1e0708df85a357d70e2708c0a11aeb5480e Mon Sep 17 00:00:00 2001 From: Jonathan Gray Date: Fri, 2 Sep 2022 05:47:02 +0000 Subject: Merge Mesa 22.1.7 --- lib/mesa/src/gallium/auxiliary/draw/draw_pipe_aaline.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) (limited to 'lib/mesa/src/gallium/auxiliary/draw/draw_pipe_aaline.c') diff --git a/lib/mesa/src/gallium/auxiliary/draw/draw_pipe_aaline.c b/lib/mesa/src/gallium/auxiliary/draw/draw_pipe_aaline.c index 49d5c65b6..7dac40785 100644 --- a/lib/mesa/src/gallium/auxiliary/draw/draw_pipe_aaline.c +++ b/lib/mesa/src/gallium/auxiliary/draw/draw_pipe_aaline.c @@ -281,9 +281,6 @@ generate_aaline_fs(struct aaline_stage *aaline) const uint newLen = tgsi_num_tokens(orig_fs->tokens) + NUM_NEW_TOKENS; aaline_fs = *orig_fs; /* copy to init */ - aaline_fs.tokens = tgsi_alloc_tokens(newLen); - if (aaline_fs.tokens == NULL) - return FALSE; memset(&transform, 0, sizeof(transform)); transform.colorOutput = -1; @@ -296,9 +293,9 @@ generate_aaline_fs(struct aaline_stage *aaline) transform.base.transform_instruction = aa_transform_inst; transform.base.transform_declaration = aa_transform_decl; - tgsi_transform_shader(orig_fs->tokens, - (struct tgsi_token *) aaline_fs.tokens, - newLen, &transform.base); + aaline_fs.tokens = tgsi_transform_shader(orig_fs->tokens, newLen, &transform.base); + if (!aaline_fs.tokens) + return false; #if 0 /* DEBUG */ debug_printf("draw_aaline, orig shader:\n"); -- cgit v1.2.3