summaryrefslogtreecommitdiffstats
path: root/src/ft_e_lcom.c
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-04-23 19:42:46 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2020-04-23 19:42:46 +0200
commit312bd95df03672f38df123038f719b113ac07ecc (patch)
tree64fe221fe92c8a677efe2e871e9cd33fe147ae4d /src/ft_e_lcom.c
parentParsed bin path in $PATH, now time to execve(2) (diff)
download42-minishell-312bd95df03672f38df123038f719b113ac07ecc.tar.gz
42-minishell-312bd95df03672f38df123038f719b113ac07ecc.tar.bz2
42-minishell-312bd95df03672f38df123038f719b113ac07ecc.tar.xz
42-minishell-312bd95df03672f38df123038f719b113ac07ecc.tar.zst
42-minishell-312bd95df03672f38df123038f719b113ac07ecc.zip
execve(2) not quite working
Diffstat (limited to 'src/ft_e_lcom.c')
-rw-r--r--src/ft_e_lcom.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ft_e_lcom.c b/src/ft_e_lcom.c
index a23b32c..6b01dc4 100644
--- a/src/ft_e_lcom.c
+++ b/src/ft_e_lcom.c
@@ -22,7 +22,8 @@ static uint8_t
uint8_t i;
i = 0;
- while (msh->bu_ref[i] && ft_strncmp(com, msh->bu_ref[i], 7) != 0)
+ while (msh->bu_ref[i] && ft_strncmp(com, msh->bu_ref[i],
+ ft_strlen(msh->bu_ref[i]) + 1) != 0)
{
i++;
}