Subject: [PATCH 06/20] upload-pack: glue code to use get_shallow_commits_by_rev_list

From: Nguyễn Thái Ngọc Duy <[email-masked]>
Date: Tue, 29 Dec 2015 19:10:29 +0700

The remaining thing to do is protocol extensions and translate the
requests to rev-list options.

Signed-off-by: Nguyễn Thái Ngọc Duy <[email-masked]>
---
 upload-pack.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/upload-pack.c b/upload-pack.c
index 4bb104c..9ae09a0 100644
--- a/upload-pack.c
+++ b/upload-pack.c
@@ -599,6 +599,18 @@ static void deepen(int depth, const struct object_array *shallows)
 	packet_flush(1);
 }
 
+static void deepen_by_rev_list(int ac, const char **av,
+			       struct object_array *shallows)
+{
+	struct commit_list *result;
+
+	result = get_shallow_commits_by_rev_list(ac, av, SHALLOW, NOT_SHALLOW);
+	send_shallow(result);
+	free_commit_list(result);
+	send_unshallow(shallows);
+	packet_flush(1);
+}
+
 static void receive_needs(void)
 {
 	struct object_array shallows = OBJECT_ARRAY_INIT;
-- 
2.3.0.rc1.137.g477eb31