/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* ft_memset.c :+: :+: :+: */ /* +:+ +:+ +:+ */ /* By: joelecle +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2020/02/14 17:06:42 by joelecle #+# #+# */ /* Updated: 2020/02/14 17:06:42 by joelecle ### ########lyon.fr */ /* */ /* ************************************************************************** */ #include void *ft_memset(void *b, int c, size_t len) { unsigned char *str; str = b; if (!len) return (b); while (len > 0) { *str = (unsigned char)c; str++; len--; } return (b); }