clear history on shell end
This commit is contained in:
parent
aba5e2f28b
commit
f67c5a0f21
@ -1,12 +1,12 @@
|
||||
/* ************************************************************************** */
|
||||
/* */
|
||||
/* :::::::: */
|
||||
/* builtin_exit.c :+: :+: */
|
||||
/* +:+ */
|
||||
/* By: whaffman <whaffman@student.codam.nl> +#+ */
|
||||
/* +#+ */
|
||||
/* ::: :::::::: */
|
||||
/* builtin_exit.c :+: :+: :+: */
|
||||
/* +:+ +:+ +:+ */
|
||||
/* By: qmennen <qmennen@student.codam.nl> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/02/20 11:32:59 by whaffman #+# #+# */
|
||||
/* Updated: 2025/02/25 16:04:17 by whaffman ######## odam.nl */
|
||||
/* Updated: 2025/02/25 20:56:29 by qmennen ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
@ -38,6 +38,7 @@ int builtin_exit(t_minishell *minishell, t_command *cmd)
|
||||
}
|
||||
//print_freelist(minishell);
|
||||
free_minishell(&minishell);
|
||||
rl_clear_history();
|
||||
exit(exit_status);
|
||||
return (FAILURE);
|
||||
}
|
||||
|
||||
@ -39,5 +39,6 @@ int main(int argc, char **argv, char **envp)
|
||||
}
|
||||
ft_lstclear_safe(minishell, &minishell->commands, free_command_list);
|
||||
free_minishell(&minishell);
|
||||
rl_clear_history();
|
||||
return (EXIT_SUCCESS);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user