libft
Loading...
Searching...
No Matches
ft_putstr_fd.c
Go to the documentation of this file.
1/* ************************************************************************** */
2/* */
3/* ::: :::::::: */
4/* ft_putstr_fd.c :+: :+: :+: */
5/* +:+ +:+ +:+ */
6/* By: tspoof <tspoof@student.hive.fi> +#+ +:+ +#+ */
7/* +#+#+#+#+#+ +#+ */
8/* Created: 2022/11/06 14:18:27 by tspoof #+# #+# */
9/* Updated: 2022/11/06 14:26:07 by tspoof ### ########.fr */
10/* */
11/* ************************************************************************** */
12
13#include "libft.h"
14
15void ft_putstr_fd(char *s, int fd)
16{
17 size_t s_len;
18
19 if (!s)
20 return ;
21 s_len = ft_strlen(s);
22 write(fd, s, s_len);
23}
void ft_putstr_fd(char *s, int fd)
Writes string to file.
size_t ft_strlen(const char *s)
Length of the string.
Definition ft_strlen.c:15