File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change 1+ 19.0.4 - fix: zpl_buffer_copy_init missing macros (thanks Ed_ on Discord)
1219.0.3 - fix: zpl_str_skip_literal reading before start of string (mbenniston)
2319.0.2 - fixed ZPL_ISIZE_MIN and MAX for 32-bit architectures (mrossetti)
3419.0.1 - Fixed zpl_array_fill ZPL_ASSERT off-by-one error
Original file line number Diff line number Diff line change @@ -33,6 +33,7 @@ typedef struct zpl_buffer_header {
3333#define zpl_buffer_count (x ) (ZPL_BUFFER_HEADER(x)->count)
3434#define zpl_buffer_capacity (x ) (ZPL_BUFFER_HEADER(x)->capacity)
3535#define zpl_buffer_end (x ) (x + (zpl_buffer_count(x) - 1))
36+ #define zpl_buffer_allocator (x ) (ZPL_BUFFER_HEADER(x)->backing)
3637
3738#define zpl_buffer_init (x , allocator , cap ) \
3839do { \
6061
6162#define zpl_buffer_copy_init (y , x ) \
6263do { \
63- zpl_buffer_init_reserve (y, zpl_buffer_allocator(x), zpl_buffer_capacity(x)); \
64+ zpl_buffer_init (y, zpl_buffer_allocator(x), zpl_buffer_capacity(x)); \
6465 zpl_memcopy(y, x, zpl_buffer_capacity(x) * zpl_size_of(*x)); \
6566 zpl_buffer_count(y) = zpl_buffer_count(x); \
6667} while (0)
You can’t perform that action at this time.
0 commit comments