summaryrefslogtreecommitdiffstats
path: root/gpu
diff options
context:
space:
mode:
authorglider@chromium.org <glider@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-09-06 08:02:40 +0000
committerglider@chromium.org <glider@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-09-06 08:02:40 +0000
commitcd4f3324ba639c1483b356137e5b6316764918c9 (patch)
tree8bbc86cd4939390ac750553c14046065a2daebc5 /gpu
parenta2361b8e81420c9efcb5c353ba8b5ba1d1d1e84d (diff)
downloadchromium_src-cd4f3324ba639c1483b356137e5b6316764918c9.zip
chromium_src-cd4f3324ba639c1483b356137e5b6316764918c9.tar.gz
chromium_src-cd4f3324ba639c1483b356137e5b6316764918c9.tar.bz2
Fix an out of bound access in GLES2DecoderWithShaderTest.VertexAttribPointer
This bug was found by AddressSanitizer TBR=gman Review URL: http://codereview.chromium.org/7828094 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@99704 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu')
-rw-r--r--gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc b/gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc
index 3081ac9..d0c63bd 100644
--- a/gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc
+++ b/gpu/command_buffer/service/gles2_cmd_decoder_unittest.cc
@@ -2826,7 +2826,7 @@ TEST_F(GLES2DecoderWithShaderTest, VertexAttribPointer) {
for (GLint size = 0; size < 5; ++size) {
for (size_t oo = 0; oo < arraysize(offset_mult); ++oo) {
GLuint offset = num_bytes * offset_mult[oo] + offset_offset[oo];
- for (size_t ss = 0; ss <= arraysize(stride_mult); ++ss) {
+ for (size_t ss = 0; ss < arraysize(stride_mult); ++ss) {
GLsizei stride = num_bytes * stride_mult[ss] + stride_offset[ss];
for (int normalize = 0; normalize < 2; ++normalize) {
bool index_good = index < static_cast<GLuint>(kNumVertexAttribs);