From 6ed4e23b8012448540125cb8ad860855ca383419 Mon Sep 17 00:00:00 2001 From: Geoffrey McRae Date: Mon, 4 Nov 2019 17:41:12 +1100 Subject: [PATCH] [common] fix objectlist_push type --- VERSION | 2 +- common/include/common/objectlist.h | 2 +- common/src/objectlist.c | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/VERSION b/VERSION index 31437b71..3caf231c 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -B1-21-gcaebddce4d+1 \ No newline at end of file +B1-22-g0851ae6f14+1 \ No newline at end of file diff --git a/common/include/common/objectlist.h b/common/include/common/objectlist.h index 2c4f621c..e547801b 100644 --- a/common/include/common/objectlist.h +++ b/common/include/common/objectlist.h @@ -25,7 +25,7 @@ typedef void (*ObjectFreeFn)(void * object); ObjectList objectlist_new (ObjectFreeFn free_fn); void objectlist_free (ObjectList * sl); -int objectlist_push (ObjectList sl, char * str); +int objectlist_push (ObjectList sl, void * object); unsigned int objectlist_count(ObjectList sl); char * objectlist_at (ObjectList sl, unsigned int index); diff --git a/common/src/objectlist.c b/common/src/objectlist.c index 56c63fb8..5fe47e25 100644 --- a/common/src/objectlist.c +++ b/common/src/objectlist.c @@ -52,7 +52,7 @@ void objectlist_free(ObjectList * ol) *ol = NULL; } -int objectlist_push (ObjectList ol, char * str) +int objectlist_push(ObjectList ol, void * object) { if (ol->count == ol->size) { @@ -61,7 +61,7 @@ int objectlist_push (ObjectList ol, char * str) } unsigned int index = ol->count; - ol->list[ol->count++] = str; + ol->list[ol->count++] = object; return index; }