aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast
diff options
context:
space:
mode:
authorKeith Whitwell <[email protected]>2009-09-23 14:40:45 +0100
committerKeith Whitwell <[email protected]>2009-09-23 18:55:46 +0100
commitbe66ff51ec98cf583044b3e53a49c41edd803134 (patch)
tree9833d492c1dcf466e029ae1e1cf262138d952f98 /src/mesa/swrast
parentbc7546476078dd520af4853f6f0d3f577ec670ec (diff)
st/mesa: trim calculated userbuffer size
In get_array_bounds we were previously defining a user buffer sized as (nr_vertices * stride). The trouble is that if the vertex data occupies less than stride bytes, the extra tailing (stride - size) bytes may extend outside the memory actually allocated by the app and caused a segfault. To fix this, define a the buffer bounds to be: ptr .. ptr + (nr-1)*stride + element_size
Diffstat (limited to 'src/mesa/swrast')
0 files changed, 0 insertions, 0 deletions