summaryrefslogtreecommitdiff
path: root/cache.h
diff options
context:
space:
mode:
authorNeeraj Singh <neerajsi@microsoft.com>2022-04-05 05:20:14 (GMT)
committerJunio C Hamano <gitster@pobox.com>2022-04-06 20:13:26 (GMT)
commit8a94d833497f3b8232684271c80a7da56f930939 (patch)
treef1f78807acd321877db3ea1294363e3b5c677826 /cache.h
parent425d290ce564ada84a5322545dbbd1866f2a29c4 (diff)
downloadgit-8a94d833497f3b8232684271c80a7da56f930939.zip
git-8a94d833497f3b8232684271c80a7da56f930939.tar.gz
git-8a94d833497f3b8232684271c80a7da56f930939.tar.bz2
core.fsync: use batch mode and sync loose objects by default on Windows
Git for Windows has defaulted to core.fsyncObjectFiles=true since September 2017. We turn on syncing of loose object files with batch mode in upstream Git so that we can get broad coverage of the new code upstream. We don't actually do fsyncs in the most of the test suite, since GIT_TEST_FSYNC is set to 0. However, we do exercise all of the surrounding batch mode code since GIT_TEST_FSYNC merely makes the maybe_fsync wrapper always appear to succeed. Signed-off-by: Neeraj Singh <neerajsi@microsoft.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'cache.h')
-rw-r--r--cache.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/cache.h b/cache.h
index ca00857..2b5f614 100644
--- a/cache.h
+++ b/cache.h
@@ -1028,6 +1028,10 @@ enum fsync_component {
FSYNC_COMPONENT_COMMIT_GRAPH | \
FSYNC_COMPONENT_INDEX)
+#ifndef FSYNC_COMPONENTS_PLATFORM_DEFAULT
+#define FSYNC_COMPONENTS_PLATFORM_DEFAULT FSYNC_COMPONENTS_DEFAULT
+#endif
+
/*
* A bitmask indicating which components of the repo should be fsynced.
*/