MCPcopy Index your code
hub / github.com/git/git / parse_gitmodules_oids

Function parse_gitmodules_oids

fetch-pack.c:923–941  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

921}
922
923static void parse_gitmodules_oids(int fd, struct oidset *gitmodules_oids)
924{
925 int len = the_hash_algo->hexsz + 1; /* hash + NL */
926
927 do {
928 char hex_hash[GIT_MAX_HEXSZ + 1];
929 int read_len = read_in_full(fd, hex_hash, len);
930 struct object_id oid;
931 const char *end;
932
933 if (!read_len)
934 return;
935 if (read_len != len)
936 die("invalid length read %d", read_len);
937 if (parse_oid_hex(hex_hash, &oid, &end) || *end != '\n')
938 die("invalid hash");
939 oidset_insert(gitmodules_oids, &oid);
940 } while (1);
941}
942
943static void add_index_pack_keep_option(struct strvec *args)
944{

Callers 2

get_packFunction · 0.85
do_fetch_pack_v2Function · 0.85

Calls 4

read_in_fullFunction · 0.85
parse_oid_hexFunction · 0.85
oidset_insertFunction · 0.85
dieFunction · 0.70

Tested by

no test coverage detected