/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ft_strchr.c :+: :+: :+: */ /* +:+ +:+ +:+ */ /* By: bchanot +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2015/11/25 13:32:36 by bchanot #+# #+# */ /* Updated: 2016/03/16 16:58:20 by bchanot ### ########.fr */ /* */ /* ************************************************************************** */ #include "libft.h" char *ft_strchr(const char *s, int c) { char *str; str = (char*)s; while (*str != (char)c && *str != '\0') str++; if (*str == (char)c) return (str); return (NULL); }