]> git.ipfire.org Git - thirdparty/git.git/commit
for_each_reflog(): reimplement using iterators
authorMichael Haggerty <mhagger@alum.mit.edu>
Sat, 18 Jun 2016 04:15:19 +0000 (06:15 +0200)
committerJunio C Hamano <gitster@pobox.com>
Mon, 20 Jun 2016 18:38:21 +0000 (11:38 -0700)
commit2880d16f09635f9d43247b27fd7e6508b992e599
treea26e3e7b2a9cab8e909bb6279cba682f187e09cb
parent0fe5043dad74352c08447eb1913df0b6c3f2731c
for_each_reflog(): reimplement using iterators

Allow references with reflogs to be iterated over using a ref_iterator.
The latter is implemented as a files_reflog_iterator, which in turn uses
dir_iterator to read the "logs" directory.

Note that reflog iteration doesn't correctly handle per-worktree
reflogs (either before or after this patch).

Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs/files-backend.c
refs/refs-internal.h