MCPcopy Create free account
hub / github.com/git/git / deepen

Function deepen

upload-pack.c:873–893  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

871static int check_ref(const struct reference *ref, void *cb_data);
872
873static void deepen(struct upload_pack_data *data, int depth)
874{
875 if (depth == INFINITE_DEPTH && !is_repository_shallow(the_repository)) {
876 int i;
877
878 for (i = 0; i < data->shallows.nr; i++) {
879 struct object *object = data->shallows.objects[i].item;
880 object->flags |= NOT_SHALLOW;
881 }
882 } else {
883 struct commit_list *result;
884
885 result = get_shallow_commits(&data->want_obj, &data->shallows,
886 data->deepen_relative, depth,
887 SHALLOW, NOT_SHALLOW);
888 send_shallow(data, result);
889 commit_list_free(result);
890 }
891
892 send_unshallow(data);
893}
894
895static void deepen_by_rev_list(struct upload_pack_data *data,
896 struct strvec *argv)

Callers 2

send_shallow_listFunction · 0.85
send_shallow_infoFunction · 0.85

Calls 5

is_repository_shallowFunction · 0.85
get_shallow_commitsFunction · 0.85
send_shallowFunction · 0.85
commit_list_freeFunction · 0.85
send_unshallowFunction · 0.85

Tested by

no test coverage detected