diff options
Diffstat (limited to 'lib/x1000-installer/test_lib/core_alloc.h')
-rw-r--r-- | lib/x1000-installer/test_lib/core_alloc.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/x1000-installer/test_lib/core_alloc.h b/lib/x1000-installer/test_lib/core_alloc.h index 6fb06649fb..2c77e3c274 100644 --- a/lib/x1000-installer/test_lib/core_alloc.h +++ b/lib/x1000-installer/test_lib/core_alloc.h @@ -25,8 +25,18 @@ #define CORE_ALLOC_H #include <stddef.h> +#include <stdbool.h> + +struct buflib_callbacks { + int (*move_callback)(int handle, void* current, void* new); + int (*shrink_callback)(int handle, unsigned hints, void* start, size_t old_size); + void (*sync_callback)(int handle, bool sync_on); +}; + +extern struct buflib_callbacks buflib_ops_locked; int core_alloc(const char* name, size_t size); +int core_alloc_ex(const char* name, size_t size, struct buflib_callbacks* cb); int core_free(int handle); void* core_get_data(int handle); |