proxy: fix void pointer cast errors

or silence warnings depending on the compiler settings.

Fixes: 9c5ca936 ("proxy: add proxy_context_resource helpers")

Signed-off-by: Ryan Neph <ryanneph@google.com>
Reviewed-by: Yiwei Zhang <zzyiwei@chromium.org>
macos/master
Ryan Neph 3 years ago
parent 06240496bf
commit 68e6f3b591
  1. 8
      src/proxy/proxy_context.c

@ -26,20 +26,20 @@ struct proxy_fence {
static inline void
proxy_context_resource_add(struct proxy_context *ctx, uint32_t res_id)
{
assert(!_mesa_hash_table_search(ctx->resource_table, (void *)res_id));
_mesa_hash_table_insert(ctx->resource_table, (void *)res_id, NULL);
assert(!_mesa_hash_table_search(ctx->resource_table, (void *)(uintptr_t)res_id));
_mesa_hash_table_insert(ctx->resource_table, (void *)(uintptr_t)res_id, NULL);
}
static inline bool
proxy_context_resource_find(struct proxy_context *ctx, uint32_t res_id)
{
return _mesa_hash_table_search(ctx->resource_table, (void *)res_id);
return _mesa_hash_table_search(ctx->resource_table, (void *)(uintptr_t)res_id);
}
static inline void
proxy_context_resource_remove(struct proxy_context *ctx, uint32_t res_id)
{
_mesa_hash_table_remove_key(ctx->resource_table, (void *)res_id);
_mesa_hash_table_remove_key(ctx->resource_table, (void *)(uintptr_t)res_id);
}
static inline bool

Loading…
Cancel
Save