summaryrefslogtreecommitdiffstats
path: root/src/ft_m_loop.c
diff options
context:
space:
mode:
authorJozanLeClerc <bousset.rudy@gmail.com>2020-04-25 17:35:48 +0200
committerJozanLeClerc <bousset.rudy@gmail.com>2020-04-25 17:35:48 +0200
commitc293dfa39ef25e37d889206cf5bc47d91e330869 (patch)
tree9f6984e7f45e5e61827c79cf77c097f701bb7749 /src/ft_m_loop.c
parentStupid bash rule (diff)
download42-minishell-c293dfa39ef25e37d889206cf5bc47d91e330869.tar.gz
42-minishell-c293dfa39ef25e37d889206cf5bc47d91e330869.tar.bz2
42-minishell-c293dfa39ef25e37d889206cf5bc47d91e330869.tar.xz
42-minishell-c293dfa39ef25e37d889206cf5bc47d91e330869.tar.zst
42-minishell-c293dfa39ef25e37d889206cf5bc47d91e330869.zip
Now handles -c option
Diffstat (limited to '')
-rw-r--r--src/ft_m_loop.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/ft_m_loop.c b/src/ft_m_loop.c
index d902d93..7f805a2 100644
--- a/src/ft_m_loop.c
+++ b/src/ft_m_loop.c
@@ -14,9 +14,7 @@
#include <stdint.h>
#include <unistd.h>
-#include "ft_d_enum.h"
#include "ft_e_lcom.h"
-#include "ft_m_loop.h"
#include "ft_m_prompt.h"
#include "ft_p_line.h"
#include "ft_s_lcom.h"
@@ -38,6 +36,8 @@ uint8_t
ft_memdel((void*)&line);
ft_e_lcom(msh);
ft_lcom_clear(&msh->curr);
+ /* TODO: segv on ';' terminated lines "msh ~> echo qwe;" */
+ /* TODO: (null): Bad address on "msh ~> echo a > asd; cat < asd" but not on "msh ~> echo a > asd; cat asd" */
/* TODO: GNL 25 leak on "msh ~> exit" */
/* TODO: "msh ~> some command \": re GNL into ft_nrealloc */
/* TODO: the chad pipes | */
@@ -48,5 +48,5 @@ uint8_t
ft_memdel((void*)&line);
}
}
- return (FT_RET_FINE);
+ return (msh->ret);
}