glhf pour les conflits

This commit is contained in:
2024-04-25 13:50:19 +02:00
parent 7f85951e43
commit fe095d4b1f
10 changed files with 31 additions and 21 deletions

View File

@ -6,7 +6,7 @@
/* By: marde-vr <marde-vr@42angouleme.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2024/03/22 14:31:13 by tomoron #+# #+# */
/* Updated: 2024/04/24 19:14:06 by tomoron ### ########.fr */
/* Updated: 2024/04/25 13:46:40 by tomoron ### ########.fr */
/* */
/* ************************************************************************** */
@ -17,13 +17,11 @@ void signal_handler_interactive(int signum)
if (signum == SIGINT)
{
g_return_code = 130;
printf("%s%s^C\n", rl_prompt, rl_line_buffer);
rl_replace_line("", 0);
printf("^C\n");
rl_on_new_line();
rl_redisplay();
}
else if (signum == SIGQUIT)
printf("%s%s", rl_prompt, rl_line_buffer);
}
void *here_doc_variables(int write, void *data)
@ -43,7 +41,6 @@ void signal_handler_here_doc(int signum)
if (signum == SIGINT)
{
printf("%s%s^C\n", rl_prompt, rl_line_buffer);
msh = here_doc_variables(0, 0);
close(msh->in_fd);
ft_exit(msh, 1);