fix: non nuiltins is now startable
This commit is contained in:
@ -5,7 +5,7 @@ char *ft_get_executable_with_path(const char *name)
|
||||
{
|
||||
char *path;
|
||||
|
||||
if (access(name, F_OK) == 0)
|
||||
if (access(name, F_OK) != 0)
|
||||
{
|
||||
ft_eprintf("minishell: %s bash: No such file or directery\n");
|
||||
return (NULL);
|
||||
@ -50,7 +50,7 @@ char *ft_get_executable_without_path(t_list **env, const char *name)
|
||||
ft_eprintf("minishell: malloc failed\n");
|
||||
break;
|
||||
}
|
||||
if (access(path, X_OK))
|
||||
if (access(path, X_OK) == 0)
|
||||
break;
|
||||
free(path);
|
||||
path = NULL;
|
||||
|
Reference in New Issue
Block a user