commit - 0a22ca1a5a1261bb7e230db211a205b68e1c3044
commit + 5a17689a92bb716ecff551f2a18eab30e762ed6b
blob - ad61697895ee0d4066a8f7b1036fc1e0ac5fd005
blob + 71b5e073f220e543460f8542ee644483ce51b73d
--- lib/pack.c
+++ lib/pack.c
char hex[3];
size_t prefix_len = strlen(id_str_prefix);
struct got_packidx_object_id *oid;
- int i;
+ uint32_t i;
SIMPLEQ_INIT(matched_ids);
return got_error_path(id_str_prefix, GOT_ERR_BAD_OBJ_ID_STR);
i = be32toh(packidx->hdr.fanout_table[id0 - 1]);
- if (i == 0)
- return NULL;
-
oid = &packidx->hdr.sorted_ids[i];
while (i < totobj && oid->sha1[0] == id0) {
char id_str[SHA1_DIGEST_STRING_LENGTH];