diff --git a/built-in.c b/built-in.c index d843550..f2b38b1 100755 --- a/built-in.c +++ b/built-in.c @@ -6,7 +6,7 @@ /* By: mea +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2022/01/06 09:02:57 by narnaud #+# #+# */ -/* Updated: 2022/05/17 17:28:52 by narnaud ### ########.fr */ +/* Updated: 2022/05/17 17:31:53 by narnaud ### ########.fr */ /* */ /* ************************************************************************** */ @@ -78,6 +78,8 @@ int ft_cd(t_datas *datas, t_command *cmd) { char *home; + if (cmd->argc > 1) + return (cmd_error("cd", "too many arguments")); if (cmd->argv[1]) { if (access(cmd->argv[1], X_OK))