diff options
Diffstat (limited to 'src/c_utils.c')
-rw-r--r-- | src/c_utils.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/c_utils.c b/src/c_utils.c index 43ed94e..16ed4f0 100644 --- a/src/c_utils.c +++ b/src/c_utils.c @@ -162,19 +162,19 @@ int16_t { if (nlines != tcaps->lpos) { - ft_printf("%d", tcaps->cpos); while (--nlines > tcaps->lpos) tputs(tgetstr("up", NULL), 1, ft_putchar); - tputs(tgetstr("cr", NULL), 1, ft_putchar); /* cr, cpos mauvaise col, bonne ligne */ tputs(tgetstr("up", NULL), 1, ft_putchar); - while (i < (tcaps->cpos)) + tputs(tgetstr("cr", NULL), 1, ft_putchar); /* cr, cpos mauvaise col, bonne ligne */ + while (i <= (tcaps->cpos + ft_strlen(msh->ps[0]))) { tputs(tgetstr("nd", NULL), 1, ft_putchar); /* cr, cpos mauvaise col, bonne ligne */ i++; } } - while (--len > tcaps->cpos) - tputs(tgetstr("le", NULL), 1, ft_putchar); + else + while (--len > tcaps->cpos) + tputs(tgetstr("le", NULL), 1, ft_putchar); } return (ret); } |