diff --git a/.fill_env.c.swp b/.fill_env.c.swp new file mode 100644 index 0000000..164f87e Binary files /dev/null and b/.fill_env.c.swp differ diff --git a/Makefile b/Makefile index 1142f9a..8d576dc 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -UTILS_SRC = utils/ft_is_in_quote.c utils/ft_strncpy.c utils/ft_strreplace.c utils/ft_strnchr.c utils/ft_split_quoted.c utils/ft_strshift.c utils/ft_quote_remover.c +UTILS_SRC = utils/ft_is_in_quote.c utils/ft_strncpy.c utils/ft_strreplace.c utils/ft_strnchr.c utils/ft_split_quoted.c utils/ft_strshift.c utils/ft_quote_remover.c utils/ft_str_is_empty.c SRCS = ${UTILS_SRC} main.c file.c infile.c outfile.c heredoc.c syntatics.c cmd.c cmds.c env.c execution.c spacer.c OBJS = ${SRCS:.c=.o} diff --git a/env.c b/env.c index cab6ec4..bb3d3f8 100644 --- a/env.c +++ b/env.c @@ -6,7 +6,7 @@ /* By: erey-bet +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2023/02/02 14:39:56 by erey-bet #+# #+# */ -/* Updated: 2023/02/16 15:18:48 by cchauvet ### ########.fr */ +/* Updated: 2023/02/16 16:24:21 by cchauvet ### ########.fr */ /* */ /* ************************************************************************** */ @@ -113,6 +113,7 @@ void env_del(void *ptr) content = ptr; free(content->key); free(content->value); + free(content); } char *get_key(char *str) diff --git a/minishell.h b/minishell.h index 966233f..c3d4f4d 100644 --- a/minishell.h +++ b/minishell.h @@ -6,7 +6,7 @@ /* By: cchauvet