diff options
Diffstat (limited to 'src/utils/file.c')
-rw-r--r-- | src/utils/file.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/utils/file.c b/src/utils/file.c index cdb2dfe..7620257 100644 --- a/src/utils/file.c +++ b/src/utils/file.c @@ -1,6 +1,5 @@ #include "file.h" -#include <stdio.h> #include <string.h> #include <utils/memory/memory.h> @@ -24,7 +23,7 @@ Code *read_whole_file(const char *path) { size_t pathLen = strlen(path); code->code = str; - code->filePath = a404m_malloc(pathLen+1); + code->filePath = a404m_malloc((pathLen+1)*sizeof(char)); memcpy(code->filePath, path, pathLen+1); |