summaryrefslogtreecommitdiff
path: root/fsck.h
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2021-03-28 13:15:49 (GMT)
committerJunio C Hamano <gitster@pobox.com>2021-03-29 02:03:10 (GMT)
commit462f5cae0f764569da4e6a7ab40ee1d3b85353ed (patch)
treecd6cd190540a07f3d74089be6fe99c5ec4f1fcd0 /fsck.h
parentc15087d17bd3c146696bfe6abf86322d79bf61ca (diff)
downloadgit-462f5cae0f764569da4e6a7ab40ee1d3b85353ed.zip
git-462f5cae0f764569da4e6a7ab40ee1d3b85353ed.tar.gz
git-462f5cae0f764569da4e6a7ab40ee1d3b85353ed.tar.bz2
fetch-pack: don't needlessly copy fsck_options
Change the behavior of the .gitmodules validation added in 5476e1efde (fetch-pack: print and use dangling .gitmodules, 2021-02-22) so we're using one "fsck_options". I found that code confusing to read. One might think that not setting up the error_func earlier means that we're relying on the "error_func" not being set in some code in between the two hunks being modified here. But we're not, all we're doing in the rest of "cmd_index_pack()" is further setup by calling fsck_set_msg_types(), and assigning to do_fsck_object. So there was no reason in 5476e1efde to make a shallow copy of the fsck_options struct before setting error_func. Let's just do this setup at the top of the function, along with the "walk" assignment. Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'fsck.h')
0 files changed, 0 insertions, 0 deletions