From abdab3156ce29d2d7f3f9ed5aba42770a0d39109 Mon Sep 17 00:00:00 2001 From: Quinten Mennen Date: Thu, 27 Feb 2025 16:46:34 +0100 Subject: [PATCH] error message instead of putstrfd --- src/executor/executor_child.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/executor/executor_child.c b/src/executor/executor_child.c index 2d05faa..d80ae8d 100644 --- a/src/executor/executor_child.c +++ b/src/executor/executor_child.c @@ -6,7 +6,7 @@ /* By: qmennen +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2025/02/12 21:25:10 by willem #+# #+# */ -/* Updated: 2025/02/27 16:20:00 by qmennen ### ########.fr */ +/* Updated: 2025/02/27 16:46:21 by qmennen ### ########.fr */ /* */ /* ************************************************************************** */ @@ -37,9 +37,7 @@ void executor_child(t_minishell *msh, t_command *command) path = executor_absolute_path(msh, command->args[0]); if (path == NULL || access(path, F_OK | X_OK) != 0) { - ft_putstr_fd(RED BOLD, 2); - ft_putstr_fd(command->args[0], 2); - ft_putstr_fd(": " RESET "command not found\n", 2); + error_msg("minishell", "command not found"); return ; } if (is_dir(path))