Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add FcntlArg::F_FULLFSYNC #407

Merged
merged 1 commit into from
Aug 26, 2016
Merged

Conversation

@@ -69,6 +71,8 @@ pub fn fcntl(fd: RawFd, arg: FcntlArg) -> Result<c_int> {
F_ADD_SEALS(flag) => libc::fcntl(fd, ffi::F_ADD_SEALS, flag.bits()),
#[cfg(target_os = "linux")]
F_GET_SEALS => libc::fcntl(fd, ffi::F_GET_SEALS),
#[cfg(target_os = "darwin")]
F_FULLFSYNC => libc::fcntl(fd, ffi::F_FULLFSYNC),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Darwin is not a valid target_os. You have to use either macos, ios or both, depending on where that flag exists. This is also, why this line does not cause our apple build to fail. Otherwise it would complain about an unkown identifier ffi::F_FULLFSYNC (see the ffi module definition further up in the file).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@untitaker untitaker force-pushed the fullfsync-fcntl branch 2 times, most recently from e7fffa0 to aa4824f Compare August 26, 2016 07:00
@untitaker
Copy link
Contributor Author

I don't have Mac OS X, so I'll test on Travis. I don't know if iOS supports that flag, but this thread seems to imply so.

@untitaker
Copy link
Contributor Author

Okay, the tests seem to pass now!

@fiveop
Copy link
Contributor

fiveop commented Aug 26, 2016

Thank you.

@homu r+

@homu
Copy link
Contributor

homu commented Aug 26, 2016

📌 Commit ae6635f has been approved by fiveop

@homu
Copy link
Contributor

homu commented Aug 26, 2016

⚡ Test exempted - status

@homu homu merged commit ae6635f into nix-rust:master Aug 26, 2016
@untitaker untitaker deleted the fullfsync-fcntl branch August 26, 2016 21:53
fiveop added a commit that referenced this pull request Aug 28, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants