]> git.ozlabs.org Git - ccan/blobdiff - ccan/timer/timer.h
timer: clean up hook allocator API
[ccan] / ccan / timer / timer.h
index 5b193250da58308f63ec98b46d3d15496e1fe049..2eb33c91ca6c49defba32233827e7786b13b7be6 100644 (file)
@@ -166,14 +166,12 @@ struct timers *timers_check(const struct timers *t, const char *abortstr);
  * timers_set_allocator - set malloc/free functions.
  * @alloc: allocator to use
  * @free: unallocator to use (@p is NULL or a return from @alloc)
  * timers_set_allocator - set malloc/free functions.
  * @alloc: allocator to use
  * @free: unallocator to use (@p is NULL or a return from @alloc)
- * @arg: argument to pass.
  *
  * This replaces the underlying malloc/free with these allocators.
  * Setting either one to NULL restores the default allocators.
  */
  *
  * This replaces the underlying malloc/free with these allocators.
  * Setting either one to NULL restores the default allocators.
  */
-void timers_set_allocator(void *(*alloc)(size_t len, void *arg),
-                         void (*free)(const void *p, void *arg),
-                         void *arg);
+void timers_set_allocator(void *(*alloc)(struct timers *, size_t len),
+                         void (*free)(struct timers *, void *p));
 
 #ifdef CCAN_TIMER_DEBUG
 #include <stdio.h>
 
 #ifdef CCAN_TIMER_DEBUG
 #include <stdio.h>