Commit Diff


commit - e8db3006452d5063d0d8cccc2ab337f6edeeebe2
commit + aac3e701f34e450da56ffe39b136263b8821d85a
blob - c54b7b77f746053c289831f1d3bb387b9c11cdf5
blob + c976951c92cbd2df0f5c45db8df28a086b6de1bd
--- lib/pack_index.c
+++ lib/pack_index.c
@@ -593,11 +593,8 @@ update_packidx(struct got_packidx *packidx, uint32_t n
 	uint32_t nindexed = be32toh(packidx->hdr.fanout_table[0xff]);
 
 	idx = find_object_idx(packidx, obj->id.sha1);
-	if (idx == -1) {
-		char hex[SHA1_DIGEST_STRING_LENGTH];
-		got_sha1_digest_to_str(obj->id.sha1, hex, sizeof(hex));
+	if (idx == -1)
 		return; /* object already indexed */
-	}
 
 	memmove(&packidx->hdr.sorted_ids[idx + 1],
 	    &packidx->hdr.sorted_ids[idx],