From 51b845a6a202b50966f50e166cfb11bcbdccbe33 Mon Sep 17 00:00:00 2001 From: Charles Date: Sat, 4 Apr 2020 15:58:24 +0200 Subject: Added ft_strsjoin, ft_strsjoinf, ft_compar_str, ft_vecsort, ft_vecpush_safe --- src/algo/ft_compar_str.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 src/algo/ft_compar_str.c (limited to 'src/algo') diff --git a/src/algo/ft_compar_str.c b/src/algo/ft_compar_str.c new file mode 100644 index 0000000..0d3e6ff --- /dev/null +++ b/src/algo/ft_compar_str.c @@ -0,0 +1,18 @@ +/* ************************************************************************** */ +/* */ +/* ::: :::::::: */ +/* ft_compar_str.c :+: :+: :+: */ +/* +:+ +:+ +:+ */ +/* By: charles +#+ +:+ +#+ */ +/* +#+#+#+#+#+ +#+ */ +/* Created: 2020/04/04 15:44:24 by charles #+# #+# */ +/* Updated: 2020/04/04 15:46:28 by charles ### ########.fr */ +/* */ +/* ************************************************************************** */ + +#include "libft_algo.h" + +int ft_compar_str(const void *s1_p, const void *s2_p) +{ + return (ft_strcmp(*(const char**)s1_p, *(const char**)s2_p)); +} -- cgit