blob: beafbb5e1c8ce12d689780c4153d36dba1a496a3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
/* ************************************************************************** */
/* LE - / */
/* / */
/* main.c .:: .:/ . .:: */
/* +:+:+ +: +: +:+:+ */
/* By: rbousset <marvin@le-101.fr> +:+ +: +: +:+ */
/* #+# #+ #+ #+# */
/* Created: 2019/10/29 08:47:37 by rbousset #+# ## ## #+# */
/* Updated: 2019/10/29 08:47:39 by rbousset ### #+. /#+ ###.fr */
/* / */
/* / */
/* ************************************************************************** */
#include <libft.h>
#include <minishell.h>
#include <stdlib.h>
#include <stddef.h>
#include <stdint.h>
#include <unistd.h>
int
main(int argc,
const char *argv[],
const char *envp[])
{
char *arg;
int8_t gnlret;
(void)argc;
(void)argv;
(void)envp;
ft_printf(FT_PS1);
while ((gnlret = get_next_line(STDIN_FILENO, &arg)) > 0)
{
ft_process_arg(arg);
ft_memdel((void*)&arg);
ft_printf(FT_PS1);
}
free(arg);
return (0);
}
|