Rename all ft_vprintf_*.c to ft_va_*.c
This commit is contained in:
31
libftprintf/ft_va_string.c
Normal file
31
libftprintf/ft_va_string.c
Normal file
@@ -0,0 +1,31 @@
|
||||
/* ************************************************************************** */
|
||||
/* */
|
||||
/* ::: :::::::: */
|
||||
/* ft_va_string.c :+: :+: :+: */
|
||||
/* +:+ +:+ +:+ */
|
||||
/* By: gbaconni@student.42lausanne.ch +#+ +:+ +#+ */
|
||||
/* +#+#+#+#+#+ +#+ */
|
||||
/* Created: 2022/01/20 11:56:37 by gbaconni #+# #+# */
|
||||
/* Updated: 2022/04/29 14:42:58 by gbaconni ### ########.fr */
|
||||
/* */
|
||||
/* ************************************************************************** */
|
||||
|
||||
#include "libftprintf.h"
|
||||
|
||||
int ft_va_string(const char *format, va_list ap)
|
||||
{
|
||||
int ret;
|
||||
char *s;
|
||||
|
||||
(void) format;
|
||||
ret = 0;
|
||||
s = va_arg(ap, char *);
|
||||
if (s == NULL)
|
||||
{
|
||||
ret = ft_puts("(null)");
|
||||
return (ret);
|
||||
}
|
||||
ret += ft_va_string_bonus(format, ap, s);
|
||||
ret += ft_puts(s);
|
||||
return (ret);
|
||||
}
|
||||
Reference in New Issue
Block a user