From f2318190bf15bed1c360b815784da15b6fdf6303 Mon Sep 17 00:00:00 2001 From: Jonathan Tan Date: Mon, 20 May 2019 16:22:31 -0700 Subject: [PATCH] UploadPack: restore inadvertently deleted line In 7b96bd812e ("UploadPack: Use reachability checker to validate non-advertised wants", 2019-05-16), a "walk.setRetainBody(false);" statement was inadvertently deleted. (An earlier version of this commit had this line in another part of the code and a review comment suggested to move it back here; the line was then deleted from the other part of the code but not readded.) Restore this line. Change-Id: I96ff6106ba9e4eef429388c83e898b3363295f69 Signed-off-by: Jonathan Tan --- org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java | 1 + 1 file changed, 1 insertion(+) diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java index dff0f9c29..3ed9886c4 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java @@ -1876,6 +1876,7 @@ private static void checkNotAdvertisedWants(UploadPack up, ObjectReader reader = up.getRevWalk().getObjectReader(); try (RevWalk walk = new RevWalk(reader)) { + walk.setRetainBody(false); // Missing "wants" throw exception here List wantsAsObjs = objectIdsToRevObjects(walk, notAdvertisedWants);