Module: Mesa Branch: master Commit: e7e0468f73034b9dc0234cc5e0c82dfa69b5ba07 URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=e7e0468f73034b9dc0234cc5e0c82dfa69b5ba07
Author: Erik Faye-Lund <[email protected]> Date: Thu Oct 1 13:25:08 2020 +0200 gallium/util: fix memory-leak When I originally wrote this code, I forgot to release the views the code creates, leaking a bit of memory that never gets cleaned up. That's not great, so let's plug it. Fixes: e8a40715a8b ("gallium/util: add blitter-support for stencil-fallback") Reviewed-by: Marek Olšák <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6960> --- src/gallium/auxiliary/util/u_blitter.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gallium/auxiliary/util/u_blitter.c b/src/gallium/auxiliary/util/u_blitter.c index ddb00650660..1de3f754d67 100644 --- a/src/gallium/auxiliary/util/u_blitter.c +++ b/src/gallium/auxiliary/util/u_blitter.c @@ -2911,4 +2911,7 @@ util_blitter_stencil_fallback(struct blitter_context *blitter, util_blitter_restore_render_cond(blitter); util_blitter_restore_constant_buffer_state(blitter); util_blitter_unset_running_flag(blitter); + + pipe_surface_reference(&dst_view, NULL); + pipe_sampler_view_reference(&src_view, NULL); } _______________________________________________ mesa-commit mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/mesa-commit
