2022-10-06 20:30:03 -04:00
|
|
|
/* ************************************************************************** */
|
|
|
|
/* */
|
|
|
|
/* ::: :::::::: */
|
2022-10-23 13:01:50 -04:00
|
|
|
/* ft_dprintflag.c :+: :+: :+: */
|
2022-10-06 20:30:03 -04:00
|
|
|
/* +:+ +:+ +:+ */
|
|
|
|
/* By: cchauvet <cchauvet@student.42angoulem +#+ +:+ +#+ */
|
|
|
|
/* +#+#+#+#+#+ +#+ */
|
2022-10-23 13:01:50 -04:00
|
|
|
/* Created: 2022/10/11 16:30:39 by cchauvet #+# #+# */
|
|
|
|
/* Updated: 2022/10/23 18:59:55 by cchauvet ### ########.fr */
|
2022-10-06 20:30:03 -04:00
|
|
|
/* */
|
|
|
|
/* ************************************************************************** */
|
|
|
|
|
2022-10-23 13:01:50 -04:00
|
|
|
#include "ft_printf.h"
|
2022-10-06 20:30:03 -04:00
|
|
|
|
2022-10-23 13:01:50 -04:00
|
|
|
int ft_dprintflag(int fd, const char *flag, va_list va)
|
2022-10-06 20:30:03 -04:00
|
|
|
{
|
2022-10-23 13:01:50 -04:00
|
|
|
if (ft_skipflag(flag) == 0)
|
|
|
|
return (-1);
|
|
|
|
flag++;
|
|
|
|
while (ft_isdigit(flag[0]))
|
|
|
|
flag += 1;
|
|
|
|
return (ft_dprintarg(fd, flag[0], va));
|
2022-10-06 20:30:03 -04:00
|
|
|
}
|