summaryrefslogtreecommitdiff
path: root/src/indexer.c
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2017-06-08 21:40:18 +0200
committerPatrick Steinhardt <ps@pks.im>2017-06-08 21:40:18 +0200
commit6c23704df5d19239f8c3d6f69da62bdbe1cf287d (patch)
tree8bb883b7d787d5e28d2f68c08b22dc311d0e258e /src/indexer.c
parent458cea5c5b820f9766cb5ba4c3d89830592d655b (diff)
downloadlibgit2-6c23704df5d19239f8c3d6f69da62bdbe1cf287d.tar.gz
settings: rename `GIT_OPT_ENABLE_SYNCHRONOUS_OBJECT_CREATION`
Initially, the setting has been solely used to enable the use of `fsync()` when creating objects. Since then, the use has been extended to also cover references and index files. As the option is not yet part of any release, we can still correct this by renaming the option to something more sensible, indicating not only correlation to objects. This commit renames the option to `GIT_OPT_ENABLE_FSYNC_GITDIR`. We also move the variable from the object to repository source code.
Diffstat (limited to 'src/indexer.c')
-rw-r--r--src/indexer.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/indexer.c b/src/indexer.c
index ce67240ce..68cd205e0 100644
--- a/src/indexer.c
+++ b/src/indexer.c
@@ -125,7 +125,7 @@ int git_indexer_new(
git_hash_ctx_init(&idx->hash_ctx);
git_hash_ctx_init(&idx->trailer);
- if (git_object__synchronous_writing)
+ if (git_repository__fsync_gitdir)
idx->do_fsync = 1;
error = git_buf_joinpath(&path, prefix, suff);