summaryrefslogtreecommitdiffstats
path: root/src/ft_exec.c
diff options
context:
space:
mode:
authorRudy Bousset <rbousset@z2r5p6.le-101.fr>2019-10-30 20:35:40 +0100
committerRudy Bousset <rbousset@z2r5p6.le-101.fr>2019-10-30 20:35:40 +0100
commitc9b17eb1b25a22ed024aaafc1e669dfbfe1bc5b0 (patch)
tree016157eeda1c0690e82096eff48b284626ed09cb /src/ft_exec.c
parentwork work (diff)
download42-minishell-c9b17eb1b25a22ed024aaafc1e669dfbfe1bc5b0.tar.gz
42-minishell-c9b17eb1b25a22ed024aaafc1e669dfbfe1bc5b0.tar.bz2
42-minishell-c9b17eb1b25a22ed024aaafc1e669dfbfe1bc5b0.tar.xz
42-minishell-c9b17eb1b25a22ed024aaafc1e669dfbfe1bc5b0.tar.zst
42-minishell-c9b17eb1b25a22ed024aaafc1e669dfbfe1bc5b0.zip
work work
Diffstat (limited to '')
-rw-r--r--src/ft_exec.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/ft_exec.c b/src/ft_exec.c
index 7177f5b..31fcaf2 100644
--- a/src/ft_exec.c
+++ b/src/ft_exec.c
@@ -10,9 +10,6 @@ ft_exec(char **app)
i = 0;
while (app[i])
i++;
- if (i < 2)
- return (execve(app[0] + 2, NULL, NULL));
- else
- return (execve(app[0] + 2, &app[1], NULL));
+ return (execve(app[0] + 2, app, NULL));
return (0);
}