mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-25 12:28:09 +01:00
notmuch-dump: use fsync instead of fdatasync
Since the file size will have changed, there is no performance benefit to calling fdatasync. Somewhat surprisingly, using fdatasync apparently causes portability problems on FreeBSD.
This commit is contained in:
parent
f6b54fbcf6
commit
f3ee655b49
1 changed files with 1 additions and 1 deletions
|
@ -169,7 +169,7 @@ notmuch_database_dump (notmuch_database_t *notmuch,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (output_file_name) {
|
if (output_file_name) {
|
||||||
ret = fdatasync (outfd);
|
ret = fsync (outfd);
|
||||||
if (ret) {
|
if (ret) {
|
||||||
fprintf (stderr, "Error syncing %s to disk: %s\n",
|
fprintf (stderr, "Error syncing %s to disk: %s\n",
|
||||||
name_for_error, strerror (errno));
|
name_for_error, strerror (errno));
|
||||||
|
|
Loading…
Reference in a new issue