diff --git a/spacer.c b/spacer.c index 8f0b24b..15ef492 100644 --- a/spacer.c +++ b/spacer.c @@ -30,7 +30,7 @@ static char *ft_spacer_after(const char *str) i++; if (ft_is_in("><|", out[i - 1])) { - while (str[i] == out[i - 1]) + while (out[i] == out[i - 1]) i++; temp = ft_strreplace(out, " ", i, i); free(out);