From 11b258841f4a15c514c49af7d378b51cd6a8ab79 Mon Sep 17 00:00:00 2001 From: Charles Date: Tue, 23 Jun 2020 09:09:17 +0200 Subject: Fixing builtin which needed to not be run in a child process, Added exit builtin --- include/minishell.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'include/minishell.h') diff --git a/include/minishell.h b/include/minishell.h index 5f4f56a..f2b237f 100644 --- a/include/minishell.h +++ b/include/minishell.h @@ -6,7 +6,7 @@ /* By: cacharle +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2020/02/26 15:33:51 by cacharle #+# #+# */ -/* Updated: 2020/06/18 13:45:27 by charles ### ########.fr */ +/* Updated: 2020/06/23 08:32:46 by charles ### ########.fr */ /* */ /* ************************************************************************** */ @@ -79,13 +79,14 @@ typedef int (*t_builtin_func)(char **argv, t_env env); ** \param func Associated function */ -struct s_builtin_entry +typedef struct { char *name; t_builtin_func func; -}; + bool child_process; +} t_builtin_entry; -t_builtin_func builtin_search_func(char *name); +t_builtin_entry *builtin_search_func(char *name); int builtin_echo(char **argv, t_env env); int builtin_cd(char **argv, t_env env); -- cgit