mesa: Ensure gl_query_object is fully initialized.

278372b47e added the uninitialized pointer
field gl_query_object:Label. A free of this pointer resulted in a crash.

This patch fixes piglit regressions with swrast introduced by
6d8dd59cf5.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=69047
Signed-off-by: Vinson Lee <vlee@freedesktop.org>
Reviewed-by: Brian Paul <brianp@vmware.com>
This commit is contained in:
Vinson Lee 2013-09-06 12:27:11 -07:00
parent e9f1f6ab42
commit 0a0f543082

View file

@ -43,7 +43,7 @@
static struct gl_query_object *
_mesa_new_query_object(struct gl_context *ctx, GLuint id)
{
struct gl_query_object *q = MALLOC_STRUCT(gl_query_object);
struct gl_query_object *q = CALLOC_STRUCT(gl_query_object);
(void) ctx;
if (q) {
q->Id = id;