fix: add: free, remove leak
This commit is contained in:
parent
e946b215cf
commit
4dfa13221c
@ -6,4 +6,5 @@ void cmd_del(void *ptr)
|
||||
|
||||
tab_free((void**)content->args);
|
||||
free(content->executable);
|
||||
free(content);
|
||||
}
|
||||
|
@ -46,6 +46,7 @@ lst **parsing_pipe(const char *str, lst** env)
|
||||
parsing_cmd(cmds_str[i], current->content, env);
|
||||
current = current->next;
|
||||
}
|
||||
tab_free((void**)cmds_str);
|
||||
return (cmds);
|
||||
}
|
||||
|
||||
@ -73,6 +74,7 @@ lst*** parsing(const char *line, lst** env)
|
||||
return (NULL);
|
||||
}
|
||||
}
|
||||
tab_free((void **) line_commas);
|
||||
tab[i] = NULL;
|
||||
return (tab);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user