diff options
| author | Christopher Uhlig | 2025-01-23 18:41:18 +0100 |
|---|---|---|
| committer | Christopher Uhlig | 2025-01-23 18:41:18 +0100 |
| commit | 18fb7cb8ae69fc3439266a154aa6b0f947d6805d (patch) | |
| tree | 2cbdd7ab727d82cb69ea7acc431e2ffcc317e4ff /src/repl.c | |
| parent | 202a5a26d1c0411c441cf12be2b22318abc4f3f9 (diff) | |
| download | minishell-18fb7cb8ae69fc3439266a154aa6b0f947d6805d.tar.gz minishell-18fb7cb8ae69fc3439266a154aa6b0f947d6805d.zip | |
a
Diffstat (limited to 'src/repl.c')
| -rw-r--r-- | src/repl.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -6,7 +6,7 @@ /* By: chuhlig <chuhlig@student.42.fr> +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/06/24 16:07:04 by dkaiser #+# #+# */ -/* Updated: 2025/01/23 12:42:57 by dkaiser ### ########.fr */ +/* Updated: 2025/01/23 17:42:33 by chuhlig ### ########.fr */ /* */ /* ************************************************************************** */ @@ -75,10 +75,12 @@ void repl(const char *prompt, t_env **env, int *promptflag) token_list = NULL; tokenizer(input, &token_list, '\0'); tokens_copy = shallow_copy_tokens(token_list); + free_tokens(tokens_copy); + // print_token_list(token_list); ast = parse(token_list, env); if (ast) set_return_code(eval(ast, env), env); free_repl(input, ast); - free_tokens(tokens_copy); + print_token_list(tokens_copy); } } |
