Merge branch 'sp/shortlog-missing-lf'

When a line to be wrapped has a solid run of non space characters
whose length exactly is the wrap width, "git shortlog -w" failed to
add a newline after such a line.

* sp/shortlog-missing-lf:
  strbuf_add_wrapped*(): Remove unused return value
  shortlog: fix wrapping lines of wraplen
This commit is contained in:
Junio C Hamano
2013-01-02 10:40:34 -08:00
4 changed files with 34 additions and 12 deletions

View File

@ -306,9 +306,8 @@ parse_done:
static void add_wrapped_shortlog_msg(struct strbuf *sb, const char *s,
const struct shortlog *log)
{
int col = strbuf_add_wrapped_text(sb, s, log->in1, log->in2, log->wrap);
if (col != log->wrap)
strbuf_addch(sb, '\n');
strbuf_add_wrapped_text(sb, s, log->in1, log->in2, log->wrap);
strbuf_addch(sb, '\n');
}
void shortlog_output(struct shortlog *log)