summaryrefslogtreecommitdiff
path: root/test-dump-split-index.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2015-09-01 16:31:29 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2015-09-01 16:31:29 -0700
commit81d0e33a225950b3837953572e4ace283341f762 (patch)
treeedcca9b75eb0ce9fbaace4ebe3c396b9ecdaaf7f /test-dump-split-index.c
parentMerge branch 'rt/remove-hold-lockfile-for-append' (diff)
parentcommit: don't rewrite shared index unnecessarily (diff)
downloadtgif-81d0e33a225950b3837953572e4ace283341f762.tar.xz
Merge branch 'dt/commit-preserve-base-index-upon-opportunistic-cache-tree-update'
When re-priming the cache-tree opportunistically while committing the in-core index as-is, we mistakenly invalidated the in-core index too aggressively, causing the experimental split-index code to unnecessarily rewrite the on-disk index file(s). * dt/commit-preserve-base-index-upon-opportunistic-cache-tree-update: commit: don't rewrite shared index unnecessarily
Diffstat (limited to 'test-dump-split-index.c')
-rw-r--r--test-dump-split-index.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/test-dump-split-index.c b/test-dump-split-index.c
index 9cf3112c9d..861d28c9b6 100644
--- a/test-dump-split-index.c
+++ b/test-dump-split-index.c
@@ -26,9 +26,11 @@ int main(int ac, char **av)
sha1_to_hex(ce->sha1), ce_stage(ce), ce->name);
}
printf("replacements:");
- ewah_each_bit(si->replace_bitmap, show_bit, NULL);
+ if (si->replace_bitmap)
+ ewah_each_bit(si->replace_bitmap, show_bit, NULL);
printf("\ndeletions:");
- ewah_each_bit(si->delete_bitmap, show_bit, NULL);
+ if (si->delete_bitmap)
+ ewah_each_bit(si->delete_bitmap, show_bit, NULL);
printf("\n");
return 0;
}