print_wrapped_text: fix output for negative indent

When providing a negative indent, it means that -indent columns were
already printed. Fix a bug where the function ate the first character
if already the first word did not fit into the first line.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Johannes Schindelin 2007-03-02 15:28:00 +01:00 коммит произвёл Junio C Hamano
Родитель 3d84df43e1
Коммит 62273826fe
1 изменённых файлов: 1 добавлений и 1 удалений

2
utf8.c
Просмотреть файл

@ -268,7 +268,7 @@ int print_wrapped_text(const char *text, int indent, int indent2, int width)
}
else {
putchar('\n');
text = bol = space + 1;
text = bol = space + isspace(*space);
space = NULL;
w = indent = indent2;
}