mirror of
https://github.com/KeyZox71/ft_minipowershell.git
synced 2025-03-15 03:16:51 +01:00
「🔨」 fix: fixed single cmd when only heredoc
This commit is contained in:
@ -6,7 +6,7 @@
|
|||||||
/* By: mmoussou <mmoussou@student.42angouleme.fr +#+ +:+ +#+ */
|
/* By: mmoussou <mmoussou@student.42angouleme.fr +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2024/06/01 14:55:06 by mmoussou #+# #+# */
|
/* Created: 2024/06/01 14:55:06 by mmoussou #+# #+# */
|
||||||
/* Updated: 2024/08/13 18:38:18 by mmoussou ### ########.fr */
|
/* Updated: 2024/08/13 19:16:03 by adjoly ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
@ -54,7 +54,6 @@ int exec_single_cmd(t_cmd *cmd, char **env, t_env *env_t, int pipe_fd[2])
|
|||||||
|
|
||||||
if (!cmd->cmd)
|
if (!cmd->cmd)
|
||||||
{
|
{
|
||||||
free_cmd(cmd);
|
|
||||||
rl_clear_history();
|
rl_clear_history();
|
||||||
get_exit_code(0);
|
get_exit_code(0);
|
||||||
return (0);
|
return (0);
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
/* By: mmoussou <mmoussou@student.42angouleme.fr +#+ +:+ +#+ */
|
/* By: mmoussou <mmoussou@student.42angouleme.fr +#+ +:+ +#+ */
|
||||||
/* +#+#+#+#+#+ +#+ */
|
/* +#+#+#+#+#+ +#+ */
|
||||||
/* Created: 2024/04/24 11:18:04 by adjoly #+# #+# */
|
/* Created: 2024/04/24 11:18:04 by adjoly #+# #+# */
|
||||||
/* Updated: 2024/08/13 16:48:59 by mmoussou ### ########.fr */
|
/* Updated: 2024/08/13 19:04:41 by adjoly ### ########.fr */
|
||||||
/* */
|
/* */
|
||||||
/* ************************************************************************** */
|
/* ************************************************************************** */
|
||||||
|
|
||||||
@ -32,7 +32,8 @@ void __parse(char *rl, t_env *env_l)
|
|||||||
return ;
|
return ;
|
||||||
get_list(&token);
|
get_list(&token);
|
||||||
exec_split_cmd(token, env_l);
|
exec_split_cmd(token, env_l);
|
||||||
ft_lstclear(&token, free_cmd);
|
if (token)
|
||||||
|
ft_lstclear(&token, free_cmd);
|
||||||
return ;
|
return ;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user