diff options
Diffstat (limited to 'src/c_input.c')
-rw-r--r-- | src/c_input.c | 33 |
1 files changed, 1 insertions, 32 deletions
diff --git a/src/c_input.c b/src/c_input.c index f26bbad..ce571ca 100644 --- a/src/c_input.c +++ b/src/c_input.c @@ -16,6 +16,7 @@ #include <signal.h> #include <term.h> +#include "c_ctrls.h" #include "c_init.h" #include "c_keys.h" #include "c_input.h" @@ -23,38 +24,6 @@ #include "m_prompt.h" #include "m_loop.h" -t_msh - *c_get_struct(int mode, t_msh **msh) -{ - static t_msh *mstruct = NULL; - - if (mode) - { - mstruct = *msh; - } - return (mstruct); -} - -void c_signal_int(int signo) -{ - t_msh *msh; - - msh = NULL; - signal(SIGINT, c_signal_int); - (void)signo; - msh = c_get_struct(0, &msh); - ft_printf("[%s]\n", msh->ps[0]); - msh->ret = 130; - ioctl(1, TIOCSTI, "\002"); -} - -void c_signal_ign(int signo) -{ - signal(SIGINT, c_signal_int); - (void)signo; - signal(SIGTSTP, SIG_IGN); -} - short c_init_line(char psx, t_caps *tcaps) { |