-
Notifications
You must be signed in to change notification settings - Fork 674
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
posix_fadvise doesn't return -1 as sentinel value #1538
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, this looks like a good change. But why just Linux and FreeBSD? I think it probably returns directly on every OS.
H-m, sounds correct. Let me update. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you also please add an entry to the FIXED section of the CHANGELOG?
b86ba85
to
1d9336b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
libc::posix_fadvise returns errnos directly rather than in the errno variable.
1d9336b
to
a607034
Compare
bors r+ |
Summary
posix_fadvise(2)
does return error number directly (i.e. not througherrno
)posix_fadvise
-binding usesErrno::result
to translate the error now, which is mis-use.