summaryrefslogtreecommitdiffstats
path: root/wayland-util.h
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2008-12-12 11:05:17 -0500
committerKristian Høgsberg <krh@hinata.localdomain>2008-12-12 12:17:47 -0500
commit864c468b4232c9529fc90cf76f5686657bab9c27 (patch)
tree67e22d387b10da88f2285aec4a41151c6ee9a80b /wayland-util.h
parent997e71eb1e6322fb91b0c8be2fe7e29c68b8b4df (diff)
downloadwayland-864c468b4232c9529fc90cf76f5686657bab9c27.tar.gz
wayland-864c468b4232c9529fc90cf76f5686657bab9c27.tar.xz
wayland-864c468b4232c9529fc90cf76f5686657bab9c27.zip
Make sure we initialize object hash.
This patch also move the hash implementation details to wayland-util.c.
Diffstat (limited to 'wayland-util.h')
-rw-r--r--wayland-util.h9
1 files changed, 4 insertions, 5 deletions
diff --git a/wayland-util.h b/wayland-util.h
index ba4ef35..5fc6451 100644
--- a/wayland-util.h
+++ b/wayland-util.h
@@ -36,11 +36,10 @@
const typeof( ((type *)0)->member ) *__mptr = (ptr); \
(type *)( (char *)__mptr - offsetof(type,member) );})
-struct wl_hash {
- struct wl_object **objects;
- uint32_t count, alloc, id;
-};
-
+struct wl_object;
+struct wl_hash;
+struct wl_hash *wl_hash_create(void);
+void wl_hash_destroy(struct wl_hash *hash);
int wl_hash_insert(struct wl_hash *hash, struct wl_object *object);
struct wl_object *wl_hash_lookup(struct wl_hash *hash, uint32_t id);
void wl_hash_delete(struct wl_hash *hash, struct wl_object *object);