mesa: Pass the context to query object delete cb to avoid null dereference.
authorEric Anholt <eric@anholt.net>
Wed, 8 Oct 2008 01:47:31 +0000 (18:47 -0700)
committerEric Anholt <eric@anholt.net>
Wed, 8 Oct 2008 01:52:12 +0000 (18:52 -0700)
src/mesa/main/queryobj.c

index 6f084b6a4f10ca41caf58bed337aaa973e1c0c7d..554e0b0d1814e96cc98dea3ff702183af9b33f32 100644 (file)
@@ -545,6 +545,6 @@ delete_queryobj_cb(GLuint id, void *data, void *userData)
 void
 _mesa_free_query_data(GLcontext *ctx)
 {
-   _mesa_HashDeleteAll(ctx->Query.QueryObjects, delete_queryobj_cb, NULL);
+   _mesa_HashDeleteAll(ctx->Query.QueryObjects, delete_queryobj_cb, ctx);
    _mesa_DeleteHashTable(ctx->Query.QueryObjects);
 }