| 543 | } |
| 544 | |
| 545 | static void validate_mixed_bloom_settings(struct commit_graph *g) |
| 546 | { |
| 547 | struct bloom_filter_settings *settings = NULL; |
| 548 | for (; g; g = g->base_graph) { |
| 549 | if (!g->bloom_filter_settings) |
| 550 | continue; |
| 551 | if (!settings) { |
| 552 | settings = g->bloom_filter_settings; |
| 553 | continue; |
| 554 | } |
| 555 | |
| 556 | if (g->bloom_filter_settings->bits_per_entry != settings->bits_per_entry || |
| 557 | g->bloom_filter_settings->num_hashes != settings->num_hashes || |
| 558 | g->bloom_filter_settings->hash_version != settings->hash_version) { |
| 559 | g->chunk_bloom_indexes = NULL; |
| 560 | g->chunk_bloom_data = NULL; |
| 561 | FREE_AND_NULL(g->bloom_filter_settings); |
| 562 | |
| 563 | warning(_("disabling Bloom filters for commit-graph " |
| 564 | "layer '%s' due to incompatible settings"), |
| 565 | oid_to_hex(&g->oid)); |
| 566 | } |
| 567 | } |
| 568 | } |
| 569 | |
| 570 | static int add_graph_to_chain(struct commit_graph *g, |
| 571 | struct commit_graph *chain, |
no test coverage detected