]> git.ipfire.org Git - thirdparty/git.git/commit - t/t5310-pack-bitmaps.sh
rev-list: disable --use-bitmap-index when pruning commits
authorJeff King <peff@peff.net>
Wed, 1 Jul 2015 18:42:17 +0000 (14:42 -0400)
committerJunio C Hamano <gitster@pobox.com>
Wed, 1 Jul 2015 19:00:50 +0000 (12:00 -0700)
commitc8a70d35090c490ce0e9f1354ef372b2887bea28
treece7496ef602855265f6980c6556cecd2bf8f0607
parent282616c72d1d08a77ca4fe1186cb708c38408d87
rev-list: disable --use-bitmap-index when pruning commits

The reachability bitmaps do not have enough information to
tell us which commits might have changed path "foo", so the
current code produces wrong answers for:

  git rev-list --use-bitmap-index --count HEAD -- foo

(it silently ignores the "foo" limiter). Instead, we should
fall back to doing a normal traversal (it is OK to fall
back rather than complain, because --use-bitmap-index is a
pure optimization, and might not kick in for other reasons,
such as there being no bitmaps in the repository).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/rev-list.c
t/t5310-pack-bitmaps.sh