This commit is contained in:
Camille Chauvet 2023-02-28 14:57:16 +01:00
parent b2c7013cf9
commit 06f6308bc4

View File

@ -123,12 +123,13 @@ static int ft_own_cmd(t_data *data, t_cmd *cmd)
data->exit_code = exit_code; data->exit_code = exit_code;
return_code = -2; return_code = -2;
} }
else
return_code = -3;
} }
if (return_code != -1 && return_code != -2) if (return_code >= 0)
{
cmd->executable = NULL;
data->exit_code = return_code; data->exit_code = return_code;
} if (return_code != -1)
cmd->executable = NULL;
return (return_code); return (return_code);
} }