From 6fe30c97aad7a4a3564e7037d64a43edcb9a2162 Mon Sep 17 00:00:00 2001 From: Charles Date: Tue, 9 Jun 2020 17:57:10 +0200 Subject: Added ft_dstrwrap, ft_splitf, fixing bug in ft_split --- src/str/ft_splitf.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 src/str/ft_splitf.c (limited to 'src/str/ft_splitf.c') diff --git a/src/str/ft_splitf.c b/src/str/ft_splitf.c new file mode 100644 index 0000000..2a1afab --- /dev/null +++ b/src/str/ft_splitf.c @@ -0,0 +1,22 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* ft_splitf.c :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: charles +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2020/06/09 17:45:52 by charles #+# #+# */ +/* Updated: 2020/06/09 17:47:17 by charles ### ########.fr */ +/* */ +/* ************************************************************************** */ + +#include "libft_str.h" + +char **ft_splitf(char *s, char delim) +{ + char **ret; + + ret = ft_split(s, delim); + free(s); + return (ret); +} -- cgit