correction memcpy pour le cas ou dst et src sont nuls
This commit is contained in:
23
srcs/ft_putstr_fd.c
Normal file
23
srcs/ft_putstr_fd.c
Normal file
@@ -0,0 +1,23 @@
|
||||
/* ************************************************************************** */
|
||||
/* */
|
||||
/* ::: :::::::: */
|
||||
/* ft_putstr_fd.c :+: :+: :+: */
|
||||
/* +:+ +:+ +:+ */
|
||||
/* By: hulamy <marvin@42.fr> +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2019/11/25 14:00:04 by hulamy #+# #+# */
|
||||
/* Updated: 2019/11/25 14:00:05 by hulamy ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
/*
|
||||
** write the string s on the given file descritor fd
|
||||
*/
|
||||
|
||||
#include "libft.h"
|
||||
|
||||
void ft_putstr_fd(char *s, int fd)
|
||||
{
|
||||
while (s && *s)
|
||||
ft_putchar_fd(*s++, fd);
|
||||
}
|
||||
Reference in New Issue
Block a user