Skip to main content
diff options
authorShawn O. Pearce2011-08-08 15:31:30 +0000
committerShawn O. Pearce2011-08-08 15:31:47 +0000
commit489604aaad8ef8d252bf31056db4de01e690fa0b (patch)
treef82d84a2278409cece0dd7bfde41279ae458d71d /org.eclipse.jgit.pgm
parent86ecf141b6e94f18702224e60e8992cafe4d02bc (diff)
Fix jgit rev-list --objects master
This flag was not being honored due to a bug in createWalk(). argWalk is always non-null when there are commits passed in on the command line. If --objects was specified, always make a new ObjectWalk for the actual execution. Change-Id: I6e1a1636f2634605d86671a83766cc1c42939821 Signed-off-by: Shawn O. Pearce <>
Diffstat (limited to 'org.eclipse.jgit.pgm')
1 files changed, 5 insertions, 3 deletions
diff --git a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/
index 474e974cd1..715cb71b43 100644
--- a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/
+++ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/
@@ -199,9 +199,11 @@ abstract class RevWalkTextBuiltin extends TextBuiltin {
protected RevWalk createWalk() {
- if (argWalk == null)
- argWalk = objects ? new ObjectWalk(db) : new RevWalk(db);
- return argWalk;
+ if (objects)
+ return new ObjectWalk(db);
+ if (argWalk != null)
+ return argWalk;
+ return new RevWalk(db);
protected int walkLoop() throws Exception {

Back to the top