Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
libnative/io: datasync() wrongly called fsync().
  • Loading branch information
nodakai committed Sep 24, 2014
1 parent c669411 commit 24bd812
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/libnative/io/file_unix.rs
Expand Up @@ -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))
Expand Down

0 comments on commit 24bd812

Please sign in to comment.