Skip to content

Commit 616e94c

Browse files
ttaylorrgitster
authored andcommitted
Documentation: fix default value for core.maxTreeDepth
When `core.maxTreeDepth` was originally introduced via be20128 (add core.maxTreeDepth config, 2023-08-31), its default value was 4096. There have since been a couple of updates to its default value that were not reflected in the documentation for `core.maxTreeDepth`: - 4d5693b (lower core.maxTreeDepth default to 2048, 2023-08-31) - b64d78a (max_tree_depth: lower it for MSVC to avoid stack overflows, 2023-11-01) Commit 4d5693b lowers the default to 2048 for platforms with smaller stack sizes, and commit b64d78a lowers the default even further when Git is compiled with MSVC. Neither of these changes were reflected in the documentation, which I noticed while merging newer releases back into GitHub's private fork (which contained the original implementation of `core.maxTreeDepth`). Update the documentation to reflect what the platform-specific default values are. Noticed-by: Keith W. Campbell <[email protected]> Signed-off-by: Taylor Blau <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 564d025 commit 616e94c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

Documentation/config/core.txt

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -741,4 +741,5 @@ core.maxTreeDepth::
741741
The maximum depth Git is willing to recurse while traversing a
742742
tree (e.g., "a/b/cde/f" has a depth of 4). This is a fail-safe
743743
to allow Git to abort cleanly, and should not generally need to
744-
be adjusted. The default is 4096.
744+
be adjusted. When Git is compiled with MSVC, the default is 512.
745+
Otherwise, the default is 2048.

0 commit comments

Comments
 (0)