summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2018-03-09 06:18:55 +1000
committerDave Airlie <airlied@redhat.com>2018-03-12 11:57:13 +1000
commite76cf1ff12703964262c7bdef6083e723f0b46ba (patch)
tree79e8ae1e90e8b6f0bc43c9c8918144126769cfd8 /src/gallium/auxiliary
parent5d4fbc2b54cb2aaea1cbb52ec087f31009f3ac76 (diff)
u_vbuf/translate: pass max_index into the set_buffer.
This fixes a memory trashing crash (not the test) seen with dEQP-GLES3.stress.draw.unaligned_data.random.203 on virgl. Reviewed-by: Marek Olšák <marek.olsak@amd.com> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'src/gallium/auxiliary')
-rw-r--r--src/gallium/auxiliary/util/u_vbuf.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gallium/auxiliary/util/u_vbuf.c b/src/gallium/auxiliary/util/u_vbuf.c
index d30a702210..95d7990c6c 100644
--- a/src/gallium/auxiliary/util/u_vbuf.c
+++ b/src/gallium/auxiliary/util/u_vbuf.c
@@ -448,7 +448,7 @@ u_vbuf_translate_buffers(struct u_vbuf *mgr, struct translate_key *key,
map -= (ptrdiff_t)vb->stride * min_index;
}
- tr->set_buffer(tr, i, map, vb->stride, ~0);
+ tr->set_buffer(tr, i, map, vb->stride, info->max_index);
}
/* Translate. */