Exemple #1
0
int						getnextline(int const fd, char **line)
{
	static t_getline	*sd = NULL;
	t_getline			*tmp;

	tmp = ft_search(sd, fd, line);
	if (tmp)
		return (first(tmp, line));
	else
		sd = ft_addlist(sd, NULL, fd);
	return (first(sd, line));
}
Exemple #2
0
static void		ft_init(t_way **way, t_che *che)
{
	t_way *t;

	t = *way;
	if (t == NULL)
	{
		*way = ft_cp(che);
	}
	else
		ft_addlist(way, ft_cp(che));
}