For some reason there was a malloc in os_read

This commit is contained in:
Krzosa Karol
2026-03-16 09:14:39 +01:00
parent 7012a41365
commit 58e28673bc
2 changed files with 3 additions and 2 deletions

View File

@@ -550,7 +550,7 @@ fn s8_t os_read(ma_arena_t *arena, s8_t path) {
fseek(fd, 0, SEEK_END);
long size = ftell(fd);
fseek(fd, 0, SEEK_SET);
char *string = malloc(size + 1);
char *string = ma_push_array(arena, char, size + 1);
fread(string, size, 1, fd);
fclose(fd);