mirror of
https://codeberg.org/la-chouette/minishell.git
synced 2025-12-05 23:18:08 +01:00
fix(redir): ensure here_doc tmp files are always deleted
This commit is contained in:
parent
3a88cbbad4
commit
ff3dfe3b84
1 changed files with 3 additions and 1 deletions
|
|
@ -6,7 +6,7 @@
|
|||
/* By: kcolin <kcolin@42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2025/04/09 16:53:02 by kcolin #+# #+# */
|
||||
/* Updated: 2025/04/29 16:40:44 by kcolin ### ########.fr */
|
||||
/* Updated: 2025/04/30 18:00:28 by kcolin ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
|
|
@ -23,6 +23,8 @@ void redirect_destroy(t_redirect *redirect)
|
|||
{
|
||||
next = redirect->next;
|
||||
free(redirect->here_doc_eof);
|
||||
if (redirect->type == FT_HEREDOC)
|
||||
unlink(redirect->redirectee.filename->word);
|
||||
worddesc_destroy(redirect->redirectee.filename);
|
||||
free(redirect->unexpanded_filename);
|
||||
free(redirect);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue