[cairo-commit] src/cairo-gl-shaders.c
Martin Robinson
mrobinson at kemper.freedesktop.org
Wed Nov 13 17:18:21 PST 2013
src/cairo-gl-shaders.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
New commits:
commit 8c73949e44d4201fafc899693964c934f7072fa6
Author: Henry Song <henry.song at samsung.com>
Date: Tue Nov 12 09:53:29 2013 -0800
gl: Fix one off issue in context cleanup
ctx->vertex_shaders is only CAIRO_GL_VAR_TYPE_MAX large, so we should
abort the loop before the index is equal to CAIRO_GL_VAR_TYPE_MAX.
Signed-off-by: Martin Robinson <mrobinson at igalia.com>
diff --git a/src/cairo-gl-shaders.c b/src/cairo-gl-shaders.c
index cc22cea..2710606 100644
--- a/src/cairo-gl-shaders.c
+++ b/src/cairo-gl-shaders.c
@@ -198,7 +198,7 @@ _cairo_gl_context_fini_shaders (cairo_gl_context_t *ctx)
{
int i;
- for (i = 0; i <= CAIRO_GL_VAR_TYPE_MAX; i++) {
+ for (i = 0; i < CAIRO_GL_VAR_TYPE_MAX; i++) {
if (ctx->vertex_shaders[i])
ctx->dispatch.DeleteShader (ctx->vertex_shaders[i]);
}
More information about the cairo-commit
mailing list