This commit is contained in:
lperrey
2021-12-22 22:19:14 +01:00
parent dfe3f6977a
commit 19c3d51726
2 changed files with 4 additions and 4 deletions

View File

@@ -6,7 +6,7 @@
/* By: lperrey <lperrey@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/11/16 01:57:38 by lperrey #+# #+# */
/* Updated: 2021/12/22 21:49:32 by lperrey ### ########.fr */
/* Updated: 2021/12/22 22:12:16 by hulamy ### ########.fr */
/* */
/* ************************************************************************** */
@@ -46,7 +46,7 @@ static void exec_builtin(t_cmd *cmd, t_all *c)
{
struct sigaction signal_behaviour;
int ret;
ft_bzero(&signal_behaviour, sizeof signal_behaviour);
signal_behaviour.sa_handler = SIG_IGN;
sigaction(SIGPIPE, &signal_behaviour, NULL);

View File

@@ -6,7 +6,7 @@
/* By: lperrey <lperrey@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/10/24 18:52:05 by lperrey #+# #+# */
/* Updated: 2021/12/22 20:23:31 by lperrey ### ########.fr */
/* Updated: 2021/12/22 22:11:40 by hulamy ### ########.fr */
/* */
/* ************************************************************************** */
@@ -24,7 +24,7 @@ int valid_command_rule1(t_token **token_list)
if (!valid_token(token_list, T_WORD))
return (0);
if (!valid_token(token_list, T_WORD) && !valid_io_redirect(token_list))
return (0);
return (0);
while (valid_token(token_list, T_WORD) || valid_io_redirect(token_list))
continue ;
if (!valid_command_separator(*token_list))