Code

Fix --boundary output
authorLinus Torvalds <torvalds@linux-foundation.org>
Sat, 5 May 2007 22:18:03 +0000 (15:18 -0700)
committerJunio C Hamano <junkio@cox.net>
Sun, 6 May 2007 04:09:34 +0000 (21:09 -0700)
"git log --boundary" incorrectly honoured the option only when
"left-right" was enabled.

Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
log-tree.c

index 8797aa14c43e693c4cb64bc93dac4fe78716558d..dbd06490f97c735171974f068b48dbdbbb992723 100644 (file)
@@ -218,10 +218,10 @@ void show_log(struct rev_info *opt, const char *sep)
                      stdout);
                if (opt->commit_format != CMIT_FMT_ONELINE)
                        fputs("commit ", stdout);
-               if (opt->left_right) {
-                       if (commit->object.flags & BOUNDARY)
-                               putchar('-');
-                       else if (commit->object.flags & SYMMETRIC_LEFT)
+               if (commit->object.flags & BOUNDARY)
+                       putchar('-');
+               else if (opt->left_right) {
+                       if (commit->object.flags & SYMMETRIC_LEFT)
                                putchar('<');
                        else
                                putchar('>');