diff options
Diffstat (limited to 'lib/sv.c')
-rw-r--r-- | lib/sv.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -60,7 +60,8 @@ sv_t sv_chop(sv_t sv, u64 size) sv_t sv_concat(arena_t *allocator, sv_t a, sv_t b) { - sv_t c = sv_make(allocator, a.data, a.size + b.size); + sv_t c = sv_make(allocator, NULL, a.size + b.size); + memcpy(c.data, a.data, a.size); memcpy(c.data + a.size, b.data, b.size); return c; } |