summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Worth <cworth@cworth.org>2009-10-12 11:07:06 -0700
committerCarl Worth <cworth@cworth.org>2009-10-12 11:07:06 -0700
commit4f569ab9d10b71183257e9facc5e09f0861cf9c6 (patch)
tree16c7aa3e3e14ae64c2a82a6d0ee09b704e3e69d5
parent71be014153f86e8e85f57841484f3c633bad931e (diff)
gl: Explicitly initialize current_target to NULL.
Be responsible here at the top level rather than relying on other levels of the code to call calloc not malloc to get correct behavior.
-rw-r--r--src/cairo-gl-surface.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cairo-gl-surface.c b/src/cairo-gl-surface.c
index 34f2ba0d..ec8a1521 100644
--- a/src/cairo-gl-surface.c
+++ b/src/cairo-gl-surface.c
@@ -116,6 +116,8 @@ _cairo_gl_context_init (cairo_gl_context_t *ctx)
ctx->max_texture_size = 0;
glGetIntegerv (GL_MAX_TEXTURE_SIZE, &ctx->max_texture_size);
+ ctx->current_target = NULL;
+
memset (ctx->glyph_cache, 0, sizeof (ctx->glyph_cache));
for (n = 0; n < ARRAY_LENGTH (ctx->glyph_cache); n++)