]> git.ipfire.org Git - thirdparty/git.git/commit
revision: move bloom keyvec precondition into function
authorToon Claes <toon@iotcl.com>
Fri, 17 Jul 2026 15:46:59 +0000 (17:46 +0200)
committerJunio C Hamano <gitster@pobox.com>
Fri, 17 Jul 2026 20:20:57 +0000 (13:20 -0700)
commitf751ee94c4dbd490eaa95bec83da9a383fd9acc4
tree59df93bc3aea5e66c85a147062e06e035e4a54d3
parent41365c2a9ba347870b80881c0d67454edd22fd49
revision: move bloom keyvec precondition into function

There are currently two callsites calling
check_maybe_different_in_bloom_filter(). They both check if
revs->bloom_keyvecs_nr is not zero before they call that function.

Move bloom_keyvecs_nr precondition into
check_maybe_different_in_bloom_filter() to simplify the code.

Note that this changes `bloom_ret` to become -1 when there are no Bloom
key vectors, which results in `count_bloom_filter_false_positive` not
being incremented. This is unobservable, as the Bloom statistics are
only reported when key vectors were set up.

Signed-off-by: Toon Claes <toon@iotcl.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
revision.c