fix of out of bounds memory access in 2 places

This commit is contained in:
nova
2026-05-05 20:07:56 +02:00
parent e5625ada08
commit 1a85a2d810
2 changed files with 4 additions and 3 deletions
+1 -1
View File
@@ -95,7 +95,7 @@ char* parse_cmd(const char *cmd, file *f){
i++;
}
out = malloc(strlen(cmd) + 1 + (strlen(f->file_name)+(count*3)) + 1);
out = malloc(strlen(cmd) + 1 + (strlen(f->file_name)+(count*3)) + 3);
pos = out;
if (offset) {