diff options
Diffstat (limited to '')
-rw-r--r-- | src/main.c | 19 |
1 files changed, 12 insertions, 7 deletions
@@ -15,21 +15,26 @@ #include <minishell.h> #include <stdlib.h> #include <stddef.h> +#include <stdint.h> #include <unistd.h> -#include <inttypes.h> int - main(void) +main(int argc, + const char *argv[], + const char *envp[]) { char *arg; - int gnlret; + int8_t gnlret; - ft_putstr(FT_PS1); - while ((gnlret= get_next_line(STDIN_FILENO, &arg)) > 0) + (void)argc; + (void)argv; + (void)envp; + ft_printf(FT_PS1); + while ((gnlret = get_next_line(STDIN_FILENO, &arg)) > 0) { ft_process_arg(arg); - free(arg); - ft_putstr(FT_PS1); + ft_memdel((void*)&arg); + ft_printf(FT_PS1); } free(arg); return (0); |