diff options
author | Nicolai Hähnle <[email protected]> | 2017-11-10 13:11:53 +0100 |
---|---|---|
committer | Nicolai Hähnle <[email protected]> | 2017-11-20 18:16:00 +0100 |
commit | 16f8da299700e714fd5aff265b8f28fe2badfa95 (patch) | |
tree | 9f61980b3d4d757fafad50259dde91ab715a322e /src/gallium/drivers/ddebug | |
parent | aaebf49ebaf34e92e99608507f42f5f42335a118 (diff) |
ddebug: fix use-after-free of streamout targets
Fixes: b47727a83ad6 ("ddebug: implement pipelined hang detection mode")
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/gallium/drivers/ddebug')
-rw-r--r-- | src/gallium/drivers/ddebug/dd_draw.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/drivers/ddebug/dd_draw.c b/src/gallium/drivers/ddebug/dd_draw.c index a25017114d8..e908410a33d 100644 --- a/src/gallium/drivers/ddebug/dd_draw.c +++ b/src/gallium/drivers/ddebug/dd_draw.c @@ -767,7 +767,7 @@ dd_copy_draw_state(struct dd_draw_state *dst, struct dd_draw_state *src) } dst->num_so_targets = src->num_so_targets; - for (i = 0; i < ARRAY_SIZE(src->so_targets); i++) + for (i = 0; i < src->num_so_targets; i++) pipe_so_target_reference(&dst->so_targets[i], src->so_targets[i]); memcpy(dst->so_offsets, src->so_offsets, sizeof(src->so_offsets)); |