minishell
ft_lstiter.c File Reference
#include <stddef.h>
#include "ft_lst.h"
Include dependency graph for ft_lstiter.c:

Go to the source code of this file.

Functions

void ft_lstiter (t_list *lst, void(*f)(void *))
 

Function Documentation

◆ ft_lstiter()

void ft_lstiter ( t_list lst,
void(*)(void *)  f 
)

Definition at line 16 of file ft_lstiter.c.

17 {
18  if (lst == NULL || f == NULL)
19  return ;
20  while (lst != NULL)
21  {
22  f(lst->content);
23  lst = lst->next;
24  }
25 }
void * content
Definition: ft_lst.h:19
struct s_list * next
Definition: ft_lst.h:20