Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use file.Sync() to flush data on linux platform
Eventually file.Sync() calls syscall syscall.Fsync, which flushes both data and metadata. While syscall.Fdatasync only flushes data. So file.Sync is safer and it's more readable. Signed-off-by: Benjamin Wang <[email protected]>
- Loading branch information