woody-woodpacker/ft_printf/libft/ft_putendl_fd.c

21 lines
1011 B
C

/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_putendl_fd.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: pbonilla <eirodeis.lepnj@gmail.com> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2020/12/01 18:27:47 by pbonilla #+# #+# */
/* Updated: 2020/12/03 17:45:49 by pbonilla ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
void ft_putendl_fd(char *s, int fd)
{
if (s)
write(fd, s, ft_strlen(s));
write(fd, "\n", 1);
}