diff options
| author | Martin Kagamino Lehoux <martin@lehoux.net> | 2025-02-10 22:07:19 +0100 |
|---|---|---|
| committer | Martin Kagamino Lehoux <martin@lehoux.net> | 2025-02-10 22:07:19 +0100 |
| commit | 803deb4a70180f987fdeb99d617631cf9a092b4d (patch) | |
| tree | f20afd4d925c28cd2226237d383c773a3cd38c0b /string.c | |
| parent | 8a9e6b1bd3be1041792311a86d8aac68b659e891 (diff) | |
fix(string): Valid string copy
Diffstat (limited to 'string.c')
| -rw-r--r-- | string.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -25,7 +25,7 @@ uint64_t Str_hash64(Str s) { } Str Str_copy(Arena *a, char *data, uintptr_t len) { - Str str = {0}; + Str str = {0,len}; str.data = new (a, char, len); if (str.len) memcpy(str.data, data, len); |
