1LIBXO(3) BSD Library Functions Manual LIBXO(3)
2
4 xo_set_allocator — set allocation functions for libxo
5
7 library “libxo”
8
10 #include <libxo/xo.h>
11 typedef void *(*xo_realloc_func_t)(void *, size_t);
12
13 typedef void (*xo_free_func_t)(void *);
14
15 void
16 xo_set_allocator(xo_realloc_func_t realloc_func,
17 xo_free_func_t free_func);
18
20 The xo_set_allocator() function allows libxo to be used in environments
21 where the standard realloc(3) and free(3) functions are not available.
22
23 realloc_func should expect the same arguments as realloc(3) and return a
24 pointer to memory following the same convention. free_func will receive
25 the same argument as free(3) and should release it, as appropriate for
26 the environment.
27
28 By default, the standard realloc(3) and free(3) functions are used.
29
31 xo_emit(3), libxo(3)
32
34 The libxo library first appeared in FreeBSD 11.0.
35
37 libxo was written by Phil Shafer <phil@freebsd.org>.
38
39
41 FreeBSD uses libxo version 1.6.0. Complete documentation can be found on
42 github:
43
44 https://juniper.github.io/libxo/1.6.0/html/index.html
45
46 libxo lives on github as:
47
48 https://github.com/Juniper/libxo
49
50 The latest release of libxo is available at:
51
52 https://github.com/Juniper/libxo/releases
53
55 The libxo library was added in FreeBSD 11.0.
56
58 Phil Shafer
59
60BSD December 4, 2014 BSD