-
Notifications
You must be signed in to change notification settings - Fork 0
/
ft_putstr_fd.c
30 lines (27 loc) · 1.06 KB
/
ft_putstr_fd.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_putstr_fd.c :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: frukundo <frukundo@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/11/02 05:18:26 by frukundo #+# #+# */
/* Updated: 2023/11/10 23:11:37 by frukundo ### ########.fr */
/* */
/* ************************************************************************** */
#include "libft.h"
#include <fcntl.h>
void ft_putstr_fd(char *s, int fd)
{
int i;
if (fd < 0)
return ;
i = 0;
if (!s)
return ;
while (s[i])
{
ft_putchar_fd(s[i], fd);
i++;
}
}