-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathft_lstclear.c
22 lines (20 loc) · 1.01 KB
/
ft_lstclear.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_lstclear.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: fulloa-s <marvin@42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/01/19 13:56:30 by fulloa-s #+# #+# */
/* Updated: 2021/01/19 15:29:50 by fulloa-s ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
void ft_lstclear(t_list **lst, void (*del)(void *))
{
while (*lst)
{
ft_lstdelone(*lst, del);
*lst = (*lst)->next;
}
}