From 22f334a19cabebf10727d7894102946ba23d0e37 Mon Sep 17 00:00:00 2001 From: Charles Date: Wed, 30 Oct 2019 18:07:21 +0100 Subject: Fixed %d segfault, merge hex_* in hex, fixed c = 0 --- parse.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'parse.c') diff --git a/parse.c b/parse.c index 71ccf35..d4ad92e 100644 --- a/parse.c +++ b/parse.c @@ -6,7 +6,7 @@ /* By: cacharle +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2019/10/29 00:11:33 by cacharle #+# #+# */ -/* Updated: 2019/10/30 04:13:56 by cacharle ### ########.fr */ +/* Updated: 2019/10/30 17:02:09 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -35,7 +35,7 @@ int parse(char *format, t_flist **flist) if ((tmp = list_new(parsed)) == NULL) return ((int)list_destroy(flist)); list_push_front(flist, tmp); - format += (*flist)->content->len; + format += (*flist)->content->fmt_len; } *flist = list_reverse(*flist); return (1); @@ -58,9 +58,9 @@ t_pformat *parse_reduced(char *fmt) pformat->precision = -1; pformat->min_width = -1; pformat->flags = 0; - pformat->len = ft_strlen(fmt); - pformat->type = fmt[pformat->len - 1]; - fmt[pformat->len - 1] = '\0'; + pformat->fmt_len = ft_strlen(fmt); + pformat->type = fmt[pformat->fmt_len - 1]; + fmt[pformat->fmt_len - 1] = '\0'; fmt = extract_standalone_flags(pformat, fmt); fmt = extract_min_width(pformat, fmt); fmt = extract_precision(pformat, fmt); -- cgit