GCC Code Coverage Report


Directory: ./
File: lib/my/my_printf/flag_c.c
Date: 2024-06-05 00:34:38
Exec Total Coverage
Lines: 8 8 100.0%
Functions: 1 1 100.0%
Branches: 0 0 -%

Line Branch Exec Source
1 /*
2 ** EPITECH PROJECT, 2023
3 ** my_printf
4 ** File description:
5 ** Flag to print a %c (a char)
6 */
7 /**
8 * @file flag_c.c
9 * @brief The file containing the flag_c function
10 * @author Nicolas TORO
11 */
12
13 #include "myprintf.h"
14
15 17 int flag_c(va_list list, formating_t *formating)
16 {
17 17 char temp = va_arg(list, int);
18 17 char str[2] = {0};
19 17 char str_finale[100] = {0};
20
21 17 str[0] = temp;
22 17 my_strcat(str_finale, str);
23 17 format_it_char(str_finale, formating, temp);
24 17 return my_putstr_fd(str_finale, formating->fd);
25 }
26