summaryrefslogtreecommitdiff
path: root/Documentation/technical
diff options
context:
space:
mode:
authorLibravatar Derrick Stolee <dstolee@microsoft.com>2018-05-01 12:47:23 +0000
committerLibravatar Junio C Hamano <gitster@pobox.com>2018-05-22 12:36:34 +0900
commit7adf526670c5c050ddc22ddcf2fdc7bd654f8fc5 (patch)
tree59cef4876425b9958663eb1aec08859ed80ab873 /Documentation/technical
parentcommit: use generation number in remove_redundant() (diff)
downloadtgif-7adf526670c5c050ddc22ddcf2fdc7bd654f8fc5.tar.xz
merge: check config before loading commits
Now that we use generation numbers from the commit-graph, we must ensure that all commits that exist in the commit-graph are loaded from that file instead of from the object database. Since the commit-graph file is only checked if core.commitGraph is true, we must check the default config before we load any commits. In the merge builtin, the config was checked after loading the HEAD commit. This was due to the use of the global 'branch' when checking merge-specific config settings. Move the config load to be between the initialization of 'branch' and the commit lookup. Without this change, a fast-forward merge would hit a BUG("bad generation skip") statement in commit.c during paint_down_to_common(). This is because the HEAD commit would be loaded with "infinite" generation but then reached by commits with "finite" generation numbers. Add a test to t5318-commit-graph.sh that exercises this code path to prevent a regression. Signed-off-by: Derrick Stolee <dstolee@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/technical')
0 files changed, 0 insertions, 0 deletions