Fixing the default of sync-before-registering
Setting 'false' as default, as suggested by Eelco. I also added a comment about the setting in the code.
This commit is contained in:
parent
25de80e2b6
commit
85799bf89e
|
@ -968,8 +968,12 @@ void LocalStore::registerValidPath(const ValidPathInfo & info)
|
||||||
|
|
||||||
void LocalStore::registerValidPaths(const ValidPathInfos & infos)
|
void LocalStore::registerValidPaths(const ValidPathInfos & infos)
|
||||||
{
|
{
|
||||||
if (queryBoolSetting("sync-before-registering", true))
|
/* sqlite will fsync by default, but the new valid paths may not be fsync-ed.
|
||||||
|
* So some may want to fsync them before registering the validity, at the
|
||||||
|
* expense of some speed of the path registering operation. */
|
||||||
|
if (queryBoolSetting("sync-before-registering", false))
|
||||||
sync();
|
sync();
|
||||||
|
|
||||||
while (1) {
|
while (1) {
|
||||||
try {
|
try {
|
||||||
SQLiteTxn txn(db);
|
SQLiteTxn txn(db);
|
||||||
|
|
Loading…
Reference in a new issue