summaryrefslogtreecommitdiff
path: root/refs/files-backend.c
diff options
context:
space:
mode:
authorLinus Arver <linus@ucla.edu>2024-05-02 04:54:21 +0000
committerJunio C Hamano <gitster@pobox.com>2024-05-02 09:57:08 -0700
commit2ade05431ebfc8c159a00202c44580754c7d42e2 (patch)
tree8ce28fe39ff3c41417fd50a7ba2ab5215d90a9f4 /refs/files-backend.c
parent3be65e6ee2f585a0aad0363c8ce7d966a6f8c2b3 (diff)
sequencer: use the trailer iterator
Instead of calling "trailer_info_get()", which is a low-level function in the trailers implementation (trailer.c), call trailer_iterator_advance(), which was specifically designed for public consumption in f0939a0eb1 (trailer: add interface for iterating over commit trailers, 2020-09-27). Avoiding "trailer_info_get()" means we don't have to worry about options like "no_divider" (relevant for parsing trailers). We also don't have to check for things like "info.trailer_start == info.trailer_end" to see whether there were any trailers (instead we can just check to see whether the iterator advanced at all). Note how we have to use "iter.raw" in order to get the same behavior as before when we iterated over the unparsed string array (char **trailers) in trailer_info. Signed-off-by: Linus Arver <linus@ucla.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'refs/files-backend.c')
0 files changed, 0 insertions, 0 deletions