mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 05:18:08 +02:00
llvmpipe: Fix bad refactoring.
'i' and 'chan' have random values here, which could cause a buffer overflow in debug builds, if chan > 4.
This commit is contained in:
parent
dc5bdbe0f9
commit
a0add0446c
1 changed files with 1 additions and 2 deletions
|
|
@ -365,8 +365,7 @@ generate_fs(struct llvmpipe_context *lp,
|
|||
0);
|
||||
|
||||
if (pos0 != -1 && outputs[pos0][2]) {
|
||||
z = LLVMBuildLoad(builder, outputs[pos0][2], "z");
|
||||
lp_build_name(z, "output%u.%u.%c", i, pos0, "xyzw"[chan]);
|
||||
z = LLVMBuildLoad(builder, outputs[pos0][2], "output.z");
|
||||
}
|
||||
|
||||
lp_build_depth_stencil_test(builder,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue