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

New syscalls #274

Merged
merged 2 commits into from
Feb 20, 2016
Merged

New syscalls #274

merged 2 commits into from
Feb 20, 2016

Conversation

abbradar
Copy link
Contributor

Part of #270

#[inline]
pub fn chown<P: ?Sized + NixPath>(path: &P, owner: Option<uid_t>, group: Option<gid_t>) -> Result<()> {
let res = try!(path.with_nix_path(|cstr| {
unsafe { ffi::chown(cstr.as_ptr(), owner.unwrap_or(0 - 1), group.unwrap_or(0 - 1)) }
Copy link
Member

Choose a reason for hiding this comment

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

could you add a tiny comment explaining the 0-1 thing?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

@kamalmarhubi
Copy link
Member

@homu r+

@homu
Copy link
Contributor

homu commented Feb 19, 2016

📌 Commit 6a2522c has been approved by kamalmarhubi

homu added a commit that referenced this pull request Feb 20, 2016
@homu
Copy link
Contributor

homu commented Feb 20, 2016

⌛ Testing commit 6a2522c with merge 7c00440...

@homu
Copy link
Contributor

homu commented Feb 20, 2016

☀️ Test successful - status

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