Module: Mesa Branch: main Commit: 33d06f8cc2c3ed6cbb562ec421b8bde47e14e206 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=33d06f8cc2c3ed6cbb562ec421b8bde47e14e206
Author: Mike Blumenkrantz <[email protected]> Date: Wed Jul 26 16:21:08 2023 -0400 lavapipe: zero fb attachment array at rp start this avoids invalid access if an attachment moves to a lower index in a smaller renderpass Reviewed-by: Dave Airlie <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24339> --- src/gallium/frontends/lavapipe/lvp_execute.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/gallium/frontends/lavapipe/lvp_execute.c b/src/gallium/frontends/lavapipe/lvp_execute.c index 6733a2dadab..1cf68cb7fe5 100644 --- a/src/gallium/frontends/lavapipe/lvp_execute.c +++ b/src/gallium/frontends/lavapipe/lvp_execute.c @@ -1713,6 +1713,7 @@ handle_begin_rendering(struct vk_cmd_queue_entry *cmd, state->framebuffer.nr_cbufs = info->colorAttachmentCount; state->color_att_count = info->colorAttachmentCount; + memset(state->framebuffer.cbufs, 0, sizeof(state->framebuffer.cbufs)); for (unsigned i = 0; i < info->colorAttachmentCount; i++) { render_att_init(&state->color_att[i], &info->pColorAttachments[i], state->poison_mem, false); if (state->color_att[i].imgv) {
