From: Christopher Uhlig Date: Mon, 5 Aug 2024 11:44:04 +0000 (+0200) Subject: update for sanityzer in condiprint X-Git-Url: https://git.dkaiser.de/?a=commitdiff_plain;h=b0cd3bb37124f19fcf285976d59ae8c0ae262b66;p=42%2Fminishell.git update for sanityzer in condiprint --- diff --git a/src/tokenizer.c b/src/tokenizer.c index a2f6fa4..bb76b9e 100644 --- a/src/tokenizer.c +++ b/src/tokenizer.c @@ -6,7 +6,7 @@ /* By: chuhlig +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2024/06/28 20:55:50 by chuhlig #+# #+# */ -/* Updated: 2024/08/05 13:41:54 by chuhlig ### ########.fr */ +/* Updated: 2024/08/05 13:43:39 by chuhlig ### ########.fr */ /* */ /* ************************************************************************** */ @@ -48,7 +48,7 @@ void conditional_print(char *string, int start_of_string, int i, exit(EXIT_FAILURE); } ft_strncpy(line, string + start_of_string, len); - line[len] = '\0'; + line[len - 1] = '\0'; while (*line == ' ' || *line == '\t') line++; if (*line != '\0')