-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.c
More file actions
38 lines (34 loc) · 1.2 KB
/
Copy pathmain.c
File metadata and controls
38 lines (34 loc) · 1.2 KB
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
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* main.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: ehouzard <ehouzard@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2018/01/10 13:01:29 by ehouzard #+# #+# */
/* Updated: 2018/05/15 18:13:01 by ehouzard ### ########.fr */
/* */
/* ************************************************************************** */
#include "fdf.h"
int ft_error(int ac)
{
if (ac != 2)
{
ft_putstr("usage: ./fdf target_file\n");
return (1);
}
return (0);
}
int main(int argc, char **argv)
{
t_limap parsed;
ft_error(argc);
if (ft_read(argv[1], &parsed))
{
ft_putstr("ERROR FILE\n");
return (1);
}
if (!(fdf_iso(&parsed)))
return (1);
return (0);
}