X-Git-Url: https://gitweb.ps.run/ps-cgit/blobdiff_plain/03afc5fe1fe70b6e44b60708c89708060e6d5a90..f3c99cf1cee25ae95ffea6188b40734e877bce20:/ui-tree.c diff --git a/ui-tree.c b/ui-tree.c index 79332fc..4bf372a 100644 --- a/ui-tree.c +++ b/ui-tree.c @@ -54,8 +54,10 @@ static void print_object(const unsigned char *sha1, char *path) } idx++; } - htmlf(linefmt, ++lineno); - html_txt(buf + start); + if (start < idx) { + htmlf(linefmt, ++lineno); + html_txt(buf + start); + } html("\n"); html("\n"); }