diff th_datastruct.h @ 731:98d12f33da7b

Change th_ringbuf_new() API.
author Matti Hamalainen <ccr@tnsp.org>
date Wed, 07 Dec 2022 00:15:38 +0200
parents 29e44a58bc73
children 79d06eb6d39f
line wrap: on
line diff
--- a/th_datastruct.h	Wed Dec 07 00:06:45 2022 +0200
+++ b/th_datastruct.h	Wed Dec 07 00:15:38 2022 +0200
@@ -64,7 +64,7 @@
 
 
 int            th_ringbuf_init(th_ringbuf_t *buf, const size_t size, void (*mdeallocator)(void *data));
-th_ringbuf_t * th_ringbuf_new(const size_t size, void (*mdeallocator)(void *data));
+int            th_ringbuf_new(th_ringbuf_t **buf, const size_t size, void (*mdeallocator)(void *data));
 int            th_ringbuf_grow(th_ringbuf_t *buf, const size_t n);
 void           th_ringbuf_free(th_ringbuf_t *buf);
 void           th_ringbuf_add(th_ringbuf_t *buf, void *ptr);