summaryrefslogtreecommitdiff
path: root/builtin-rev-list.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2007-10-03 04:28:24 -0700
committerJunio C Hamano <gitster@pobox.com>2007-10-03 04:28:24 -0700
commitcc61ae82ec581f6cf1a38a45aaef894f085ccb16 (patch)
treef6127d78a1616ae57452cfb1d9aa9a5f36392af2 /builtin-rev-list.c
parent66d4035e1099477aa488c24c0c081ee764f85868 (diff)
parent55246aac6717e86c14f31391ac903ed810d1a9a0 (diff)
downloadgit-cc61ae82ec581f6cf1a38a45aaef894f085ccb16.tar.gz
Merge branch 'mv/unknown'
* mv/unknown: Don't use "<unknown>" for placeholders and suppress printing of empty user formats.
Diffstat (limited to 'builtin-rev-list.c')
-rw-r--r--builtin-rev-list.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/builtin-rev-list.c b/builtin-rev-list.c
index 414b2f32b2..33726b8d84 100644
--- a/builtin-rev-list.c
+++ b/builtin-rev-list.c
@@ -84,7 +84,8 @@ static void show_commit(struct commit *commit)
strbuf_init(&buf, 0);
pretty_print_commit(revs.commit_format, commit,
&buf, revs.abbrev, NULL, NULL, revs.date_mode);
- printf("%s%c", buf.buf, hdr_termination);
+ if (buf.len)
+ printf("%s%c", buf.buf, hdr_termination);
strbuf_release(&buf);
}
maybe_flush_or_die(stdout, "stdout");