Changeset View
Changeset View
Standalone View
Standalone View
head/lib/libc/sys/chflags.2
Show All 22 Lines | |||||
.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT | ||||
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | ||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | ||||
.\" SUCH DAMAGE. | .\" SUCH DAMAGE. | ||||
.\" | .\" | ||||
.\" @(#)chflags.2 8.3 (Berkeley) 5/2/95 | .\" @(#)chflags.2 8.3 (Berkeley) 5/2/95 | ||||
.\" $FreeBSD$ | .\" $FreeBSD$ | ||||
.\" | .\" | ||||
.Dd March 22, 2013 | .Dd October 20, 2018 | ||||
.Dt CHFLAGS 2 | .Dt CHFLAGS 2 | ||||
.Os | .Os | ||||
.Sh NAME | .Sh NAME | ||||
.Nm chflags , | .Nm chflags , | ||||
.Nm lchflags , | .Nm lchflags , | ||||
.Nm fchflags , | .Nm fchflags , | ||||
.Nm chflagsat | .Nm chflagsat | ||||
.Nd set file flags | .Nd set file flags | ||||
▲ Show 20 Lines • Show All 49 Lines • ▼ Show 20 Lines | |||||
are constructed by a bitwise-inclusive OR of flags from the following list, | are constructed by a bitwise-inclusive OR of flags from the following list, | ||||
defined in | defined in | ||||
.In fcntl.h : | .In fcntl.h : | ||||
.Bl -tag -width indent | .Bl -tag -width indent | ||||
.It Dv AT_SYMLINK_NOFOLLOW | .It Dv AT_SYMLINK_NOFOLLOW | ||||
If | If | ||||
.Fa path | .Fa path | ||||
names a symbolic link, then the flags of the symbolic link are changed. | names a symbolic link, then the flags of the symbolic link are changed. | ||||
.It Dv AT_BENEATH | |||||
Only allow to change flags for a file which is beneath of | |||||
the starting directory. | |||||
.El | .El | ||||
.Pp | .Pp | ||||
If | If | ||||
.Fn chflagsat | .Fn chflagsat | ||||
is passed the special value | is passed the special value | ||||
.Dv AT_FDCWD | .Dv AT_FDCWD | ||||
in the | in the | ||||
.Fa fd | .Fa fd | ||||
▲ Show 20 Lines • Show All 192 Lines • ▼ Show 20 Lines | |||||
.It Bq Er EIO | .It Bq Er EIO | ||||
An | An | ||||
.Tn I/O | .Tn I/O | ||||
error occurred while reading from or writing to the file system. | error occurred while reading from or writing to the file system. | ||||
.It Bq Er EOPNOTSUPP | .It Bq Er EOPNOTSUPP | ||||
The underlying file system does not support file flags, or | The underlying file system does not support file flags, or | ||||
does not support all of the flags set in | does not support all of the flags set in | ||||
.Fa flags . | .Fa flags . | ||||
.It Bq Er ENOTCAPABLE | |||||
The | |||||
.Dv AT_BENEATH | |||||
flag was specified but | |||||
.Fa path | |||||
is not strictly relative to the starting directory. | |||||
For example, | |||||
.Fa path | |||||
is absolute or includes a ".." component that escapes the starting directory. | |||||
.El | .El | ||||
.Sh SEE ALSO | .Sh SEE ALSO | ||||
.Xr chflags 1 , | .Xr chflags 1 , | ||||
.Xr fflagstostr 3 , | .Xr fflagstostr 3 , | ||||
.Xr strtofflags 3 , | .Xr strtofflags 3 , | ||||
.Xr init 8 , | .Xr init 8 , | ||||
.Xr mount_unionfs 8 | .Xr mount_unionfs 8 | ||||
.Sh HISTORY | .Sh HISTORY | ||||
Show All 14 Lines |