diff --git a/src/redirect/redirect_get_inputs.c b/src/redirect/redirect_get_inputs.c index 705ac5e..f68d9af 100644 --- a/src/redirect/redirect_get_inputs.c +++ b/src/redirect/redirect_get_inputs.c @@ -18,14 +18,13 @@ static void process_heredoc(t_minishell *ms, t_token *heredoc, t_token *delim) int fd; fd = open(".ms_heredoc", O_WRONLY | O_CREAT | O_TRUNC, 0644); - if (fd < 0) + if (fd < 0) //TODO: Will this work? return ; - while (TRUE) { - line = readline("heredoc>"); - if ((*line && ft_strcmp(line, delim->value) == 0) || !line) + line = readline(">"); + if ((*line && ft_strcmp(line, delim->value) == 0) || !line) //TODO: What if not line? break ; if (!*line) ft_putendl_fd("", fd);