radeonsi: Clear uninitialized variable
authorDrew Davenport <ddavenport@chromium.org>
Mon, 27 Jan 2020 18:13:19 +0000 (11:13 -0700)
committerMarge Bot <eric+marge@anholt.net>
Tue, 28 Jan 2020 16:29:48 +0000 (16:29 +0000)
|view| was not initialized leading to flaky test failures in SkQP
test unitTest_ES2BlendWithNoTexture.

Fixes: 029bfa3d253 "radeonsi: add ability to bind images as image buffers"
Reviewed-by: Bas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Tested-by: Marge Bot <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3592>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/merge_requests/3592>

src/gallium/drivers/radeonsi/si_descriptors.c

index 193029820e54bddc1e7064f4769fcc152a3b3ffb..fa2174bac5d084a412dd0d07f974c0d0da412c29 100644 (file)
@@ -903,7 +903,7 @@ void si_update_ps_colorbuf0_slot(struct si_context *sctx)
 
        if (surf) {
                struct si_texture *tex = (struct si_texture*)surf->texture;
-               struct pipe_image_view view;
+               struct pipe_image_view view = {0};
 
                assert(tex);
                assert(!tex->is_depth);