mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-27 19:10:14 +01:00
u_vbuf: Fix leak
Reported by Coverity: data is heap-allocated, but only freed in the info->index_size != 0 branch. Signed-off-by: Ernestas Kulik <ernestas.kulik@gmail.com> Signed-off-by: Marek Olšák <marek.olsak@amd.com> Cc: 18.2 <mesa-stable@lists.freedesktop.org>
This commit is contained in:
parent
2e59b88903
commit
ea1e50cc16
1 changed files with 1 additions and 0 deletions
|
|
@ -1334,6 +1334,7 @@ void u_vbuf_draw_vbo(struct u_vbuf *mgr, const struct pipe_draw_info *info)
|
|||
end_vertex = MAX2(end_vertex, start + count);
|
||||
end_instance = MAX2(end_instance, start_instance + instance_count);
|
||||
}
|
||||
free(data);
|
||||
|
||||
/* Set the final counts. */
|
||||
new_info.count = end_vertex - new_info.start;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue