]> source.dussan.org Git - jgit.git/commitdiff
log: Fix commit headers and -p flag 29/1529/1
authorShawn O. Pearce <spearce@spearce.org>
Sat, 4 Sep 2010 06:33:28 +0000 (23:33 -0700)
committerShawn O. Pearce <spearce@spearce.org>
Sat, 4 Sep 2010 06:55:45 +0000 (23:55 -0700)
We weren't flushing the commit message before the diff output, which
meant the headers and message showed randomly interleaved with the
diff rather than immediately before.

Change-Id: I6cefab8d40e9d40c937e9deb12911188fec41b26
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/Log.java

index 8eb2e54dc5a0c40cfe20486bdc07189829f58f04..92cb70d4c4c8900fd20c30e552176982e4b76135 100644 (file)
@@ -234,10 +234,10 @@ class Log extends RevWalkTextBuiltin {
                if (showNameAndStatusOnly)
                        Diff.nameStatus(out, diffFmt.scan(a, b));
                else {
+                       out.flush();
                        diffFmt.format(a, b);
                        diffFmt.flush();
                }
                out.println();
-               out.flush();
        }
 }