diff options
| author | NODA, Kai <nodakai@gmail.com> | 2014-09-22 08:03:54 +0800 |
|---|---|---|
| committer | NODA, Kai <nodakai@gmail.com> | 2014-09-24 09:06:17 +0800 |
| commit | 24bd8124eac3e3ac6c51527e21bbc9f0f3a9c298 (patch) | |
| tree | 32375787c751fd2e88880b678732e98e6f682b4a | |
| parent | c669411afa76bdc92369a3a193e9393364d42370 (diff) | |
| download | rust-24bd8124eac3e3ac6c51527e21bbc9f0f3a9c298.tar.gz rust-24bd8124eac3e3ac6c51527e21bbc9f0f3a9c298.zip | |
libnative/io: datasync() wrongly called fsync().
| -rw-r--r-- | src/libnative/io/file_unix.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libnative/io/file_unix.rs b/src/libnative/io/file_unix.rs index 3c49e1c40d6..90fbc7729d4 100644 --- a/src/libnative/io/file_unix.rs +++ b/src/libnative/io/file_unix.rs @@ -303,7 +303,7 @@ impl rtio::RtioFileStream for CFile { self.flush().and_then(|()| self.fd.fsync()) } fn datasync(&mut self) -> IoResult<()> { - self.flush().and_then(|()| self.fd.fsync()) + self.flush().and_then(|()| self.fd.datasync()) } fn truncate(&mut self, offset: i64) -> IoResult<()> { self.flush().and_then(|()| self.fd.truncate(offset)) |
