diff --git a/pack-bitmap.c b/pack-bitmap.c index a56ceb9441..f772d3cb7f 100644 --- a/pack-bitmap.c +++ b/pack-bitmap.c @@ -1759,7 +1759,7 @@ int test_bitmap_hashes(struct repository *r) struct object_id oid; uint32_t i, index_pos; - if (!bitmap_git->hashes) + if (!bitmap_git || !bitmap_git->hashes) goto cleanup; for (i = 0; i < bitmap_num_objects(bitmap_git); i++) {