From 9580179dfb42d5b81ff6ec9704b82a556c7f1229 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Tue, 6 Dec 2005 15:41:43 +0000 Subject: C++ fixes, mostly casts (Stephane Conversy) --- src/mesa/tnl/t_context.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/mesa/tnl/t_context.c') diff --git a/src/mesa/tnl/t_context.c b/src/mesa/tnl/t_context.c index 30b2947323..d9777bfe6d 100644 --- a/src/mesa/tnl/t_context.c +++ b/src/mesa/tnl/t_context.c @@ -87,11 +87,11 @@ _tnl_CreateContext( GLcontext *ctx ) _tnl_vtx_init( ctx ); if (ctx->_MaintainTnlProgram) { - tnl->vp_cache = MALLOC(sizeof(*tnl->vp_cache)); + tnl->vp_cache = (struct tnl_cache *) MALLOC(sizeof(*tnl->vp_cache)); tnl->vp_cache->size = 5; tnl->vp_cache->n_items = 0; - tnl->vp_cache->items = MALLOC(tnl->vp_cache->size * - sizeof(*tnl->vp_cache->items)); + tnl->vp_cache->items = (struct tnl_cache_item**) + _mesa_malloc(tnl->vp_cache->size * sizeof(*tnl->vp_cache->items)); _mesa_memset(tnl->vp_cache->items, 0, tnl->vp_cache->size * sizeof(*tnl->vp_cache->items)); -- cgit v1.2.3