diff options
Diffstat (limited to 'libft/src')
| -rw-r--r-- | libft/src/ft_delwords.c | 28 | 
1 files changed, 28 insertions, 0 deletions
diff --git a/libft/src/ft_delwords.c b/libft/src/ft_delwords.c new file mode 100644 index 0000000..79c671d --- /dev/null +++ b/libft/src/ft_delwords.c @@ -0,0 +1,28 @@ +/* ************************************************************************** */ +/*                                                                            */ +/*                                                        :::      ::::::::   */ +/*   ft_delwords.c                                      :+:      :+:    :+:   */ +/*                                                    +:+ +:+         +:+     */ +/*   By: rbousset <marvin@42.fr>                    +#+  +:+       +#+        */ +/*                                                +#+#+#+#+#+   +#+           */ +/*   Created: 2020/02/14 17:19:27 by rbousset          #+#    #+#             */ +/*   Updated: 2020/02/14 17:19:29 by rbousset         ###   ########lyon.fr   */ +/*                                                                            */ +/* ************************************************************************** */ + +#include <libft.h> +#include <stddef.h> + +void +	ft_delwords(char **words) +{ +	size_t	i; + +	i = 0; +	while (words[i]) +	{ +		ft_memdel((void*)&words[i]); +		i++; +	} +	ft_memdel((void*)&words); +}  | 
