]> source.dussan.org Git - jgit.git/commitdiff
ReceivePack: Correct type of not provided object 73/573/1
authorShawn O. Pearce <spearce@spearce.org>
Fri, 16 Apr 2010 15:55:44 +0000 (08:55 -0700)
committerShawn O. Pearce <spearce@spearce.org>
Sat, 17 Apr 2010 00:04:37 +0000 (17:04 -0700)
If a tree was referenced but not provided in the pack, report it
as a missing tree and not as a missing blob.

Change-Id: Iab05705349cdf0d30cc3f8afc6698a8d2a941343
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
org.eclipse.jgit/src/org/eclipse/jgit/transport/ReceivePack.java

index cce0a17d003af47819ab6c924935c0674fb2ae15..85522edc49a9cbe4d43282d9c8a119d03441b860 100644 (file)
@@ -827,7 +827,7 @@ public class ReceivePack {
                                throw new MissingObjectException(o, Constants.TYPE_BLOB);
 
                        if (ensureObjectsProvidedVisible && !providedObjects.contains(o))
-                               throw new MissingObjectException(o, Constants.TYPE_BLOB);
+                               throw new MissingObjectException(o, o.getType());
                }
        }