int ft_action(t_list *list) { t_list *tmp; ft_putstr(tgetstr("cl", NULL)); tmp = list; ft_action2(tmp); tmp = tmp->next; while (tmp != list) { ft_action2(tmp); tmp = tmp->next; } return (0); }
int ft_action(char *f, va_list ap) { int len; len = 1; while (ft_is_arg(f[len])) ++len; if (f[len] == 'i' || f[len] == 'd') ft_action_d(f, len, ap, f[len]); else if (f[len] == 'D') ft_action_ud(f, len, ap, f[len]); else if (f[len] == 'U') ft_action_zu(f, len, ap, f[len]); else if (f[len] == 'u') ft_action_u(f, len, ap, f[len]); else if (f[len] == 'O') ft_action_uo(f, len, ap); else if (f[len] == 'o') ft_action_o(f, len, ap); else if (f[len] == 'X') ft_action_ux(f, len, ap); else if (f[len] == 'x') ft_action_x(f, len, ap); else return (ft_action2(f, ap, len)); return (len + 1); }