commit - 817c5a18db169317b90ca35d48c3c43c8f8ce537
commit + 3413160a99d35c17f3e9d1c472eed30769530007
blob - e50ad5cee685e50dfd69627e821e2008f4918d94
blob + b185f2ed51fdd7f9637f01d99efc13e20d86763a
--- lib/pack.c
+++ lib/pack.c
}
static int
-get_object_idx(struct got_packidx *packidx, struct got_object_id *id,
- struct got_repository *repo)
+get_object_idx(struct got_packidx *packidx, struct got_object_id *id)
{
u_int8_t id0 = id->sha1[0];
uint32_t totobj = betoh32(packidx->hdr.fanout_table[0xff]);
for (i = 0; i < nitems(repo->packidx_cache); i++) {
if (repo->packidx_cache[i] == NULL)
break;
- *idx = get_object_idx(repo->packidx_cache[i], id, repo);
+ *idx = get_object_idx(repo->packidx_cache[i], id);
if (*idx != -1) {
*packidx = repo->packidx_cache[i];
return NULL;
if (err)
goto done;
- *idx = get_object_idx(*packidx, id, repo);
+ *idx = get_object_idx(*packidx, id);
if (*idx != -1) {
err = NULL; /* found the object */
err = cache_packidx(*packidx, repo);
goto done;
/* Delta base must be in the same pack file. */
- idx = get_object_idx(packidx, &id, repo);
+ idx = get_object_idx(packidx, &id);
if (idx == -1) {
err = got_error(GOT_ERR_BAD_PACKFILE);
goto done;