diff options
author | JozanLeClerc <bousset.rudy@gmail.com> | 2020-08-15 18:20:23 +0200 |
---|---|---|
committer | JozanLeClerc <bousset.rudy@gmail.com> | 2020-08-15 18:20:23 +0200 |
commit | 7df3f33f3c644e53577b53fed433bfe9a4ff0715 (patch) | |
tree | 226cb02e6cd877df38bd6fafa5066b643380d71d /src/m_argv.c | |
parent | Can read scripts, but need to handle fails (diff) | |
download | 42-minishell-7df3f33f3c644e53577b53fed433bfe9a4ff0715.tar.gz 42-minishell-7df3f33f3c644e53577b53fed433bfe9a4ff0715.tar.bz2 42-minishell-7df3f33f3c644e53577b53fed433bfe9a4ff0715.tar.xz 42-minishell-7df3f33f3c644e53577b53fed433bfe9a4ff0715.tar.zst 42-minishell-7df3f33f3c644e53577b53fed433bfe9a4ff0715.zip |
Error handling ok
Diffstat (limited to 'src/m_argv.c')
-rw-r--r-- | src/m_argv.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/m_argv.c b/src/m_argv.c index 1e23bae..0c32e3b 100644 --- a/src/m_argv.c +++ b/src/m_argv.c @@ -15,6 +15,7 @@ #include <fcntl.h> #include <unistd.h> +#include "f_fail.h" #include "d_define.h" #include "m_comm.h" #include "m_loop.h" @@ -44,7 +45,7 @@ uint8_t else { if ((fd = open(*(argv + 1), O_RDONLY)) < 0) - f_open_file(msh); + f_open_file(*(argv + 1), msh); msh->ret = m_loop(fd, msh); close(fd); } |