summaryrefslogtreecommitdiff
path: root/libft/ft_putchar_fd.c
blob: 120c9ccb4e6f0cc71f7f277bc34a1f6142e2862b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/* ************************************************************************** */
/*                                                                            */
/*                                                        :::      ::::::::   */
/*   ft_putchar_fd.c                                    :+:      :+:    :+:   */
/*                                                    +:+ +:+         +:+     */
/*   By: kdx    <kdx   @student.42angouleme.fr      +#+  +:+       +#+        */
/*                                                +#+#+#+#+#+   +#+           */
/*   Created: 2022/09/29 02:11:58 by kdx               #+#    #+#             */
/*   Updated: 2022/10/04 04:54:01 by kdx              ###   ########.fr       */
/*                                                                            */
/* ************************************************************************** */

#include "libft.h"
#include <unistd.h>

size_t	ft_putchar_fd(char c, int fd)
{
	return (write(fd, &c, 1) == 1);
}