finally \o/

added ft_printf to libft
finalised ans tested ft_getline
This commit is contained in:
vagrant
2019-03-07 22:29:34 +00:00
parent 55767c36c6
commit 13d96a14d8
18 changed files with 75 additions and 81 deletions

View File

@@ -6,11 +6,11 @@
/* By: klebon <klebon@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2018/05/19 08:51:48 by klebon #+# #+# */
/* Updated: 2018/10/30 12:35:10 by klebon ### ########.fr */
/* Updated: 2019/03/07 22:22:07 by tmaze ### ########.fr */
/* */
/* ************************************************************************** */
#include "libftprintf.h"
#include "libft.h"
char *handle_output_char(t_conv *field, va_list ap)
{
@@ -22,7 +22,7 @@ char *handle_output_char(t_conv *field, va_list ap)
else
c = (unsigned char)va_arg(ap, int);
field->str_size = (field->fl_witdth > 1) ? field->fl_witdth : 1;
if (!(output = ft_strnewb(field->str_size)))
if (!(output = ft_strnew(field->str_size)))
return (NULL);
output[0] = c;
ft_align_wchar(output, field);