gallium: fix cast for size calc of pipe_blend_state
authorRoland Scheidegger <sroland@vmware.com>
Mon, 25 Jan 2010 15:31:21 +0000 (16:31 +0100)
committerRoland Scheidegger <sroland@vmware.com>
Mon, 25 Jan 2010 15:31:21 +0000 (16:31 +0100)
src/gallium/auxiliary/cso_cache/cso_context.c

index c8fdfc81248f7fdbeb02cf1332598c9bcafefcc0..c479c360643142b114d28405bfa2156551aa8370 100644 (file)
@@ -315,7 +315,7 @@ enum pipe_error cso_set_blend(struct cso_context *ctx,
    void *handle;
 
    key_size = templ->independent_blend_enable ? sizeof(struct pipe_blend_state) :
-              (void *)&(templ->rt[1]) - (void *)templ;
+              (char *)&(templ->rt[1]) - (char *)templ;
    hash_key = cso_construct_key((void*)templ, key_size);
    iter = cso_find_state_template(ctx->cache, hash_key, CSO_BLEND, (void*)templ);