diff options
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/revwalk/StartGenerator.java')
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/revwalk/StartGenerator.java | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/StartGenerator.java b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/StartGenerator.java index fbff027784..7fb958bbb6 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/StartGenerator.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/StartGenerator.java @@ -132,14 +132,20 @@ class StartGenerator extends Generator { } walker.queue = q; - g = new PendingGenerator(w, pending, rf, pendingOutputType); - if (boundary) { - // Because the boundary generator may produce uninteresting - // commits we cannot allow the pending generator to dispose - // of them early. - // - ((PendingGenerator) g).canDispose = false; + if (walker instanceof DepthWalk) { + DepthWalk dw = (DepthWalk) walker; + g = new DepthGenerator(dw, pending); + } else { + g = new PendingGenerator(w, pending, rf, pendingOutputType); + + if (boundary) { + // Because the boundary generator may produce uninteresting + // commits we cannot allow the pending generator to dispose + // of them early. + // + ((PendingGenerator) g).canDispose = false; + } } if ((g.outputType() & NEEDS_REWRITE) != 0) { |