Skip to content

Commit

Permalink
Update chown help with a link and adding cap warning
Browse files Browse the repository at this point in the history
Linked to chown(2) manpage on the web which expands on chown call behaviour.
  • Loading branch information
grinapo authored and gitbot committed Feb 20, 2025
1 parent d0226cf commit 497ac2b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion std/src/os/unix/fs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -989,7 +989,8 @@ impl DirBuilderExt for fs::DirBuilder {
///
/// Be aware that changing owner clears the `suid` and `sgid` permission bits in most cases
/// according to POSIX, usually even if the user is root. The sgid is not cleared when
/// the file is non-group-executable.
/// the file is non-group-executable. See: <https://www.man7.org/linux/man-pages/man2/chown.2.html>
/// This call may also clear file capabilities, if there was any.
///
/// If called on a symbolic link, this will change the owner and group of the link target. To
/// change the owner and group of the link itself, see [`lchown`].
Expand Down

0 comments on commit 497ac2b

Please sign in to comment.