mirror of https://github.com/mkerrisk/man-pages
stat.2: Minor fixes
Reported-by: Andreas Grünbacher <andreas.gruenbacher@gmail.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
parent
bba094e3f9
commit
44b1f5a0c2
25
man2/stat.2
25
man2/stat.2
|
@ -293,13 +293,24 @@ The field
|
|||
is changed by writing or by setting inode information
|
||||
(i.e., owner, group, link count, mode, etc.).
|
||||
.PP
|
||||
The following mask values are defined for the file type component of the
|
||||
POSIX refers to the
|
||||
.I st_mode
|
||||
bits corresponding to the mask
|
||||
.B S_IFMT
|
||||
(see below) as the
|
||||
.IR "file type" ,
|
||||
the 12 bits corresponding to the mask 07777 as the
|
||||
.IR "file mode bits"
|
||||
and the least significant 9 bits (0777) as the
|
||||
.IR "file permission bits" .
|
||||
.PP
|
||||
The following mask values are defined for the file type of the
|
||||
.I st_mode
|
||||
field:
|
||||
.in +4n
|
||||
.TS
|
||||
lB l l.
|
||||
S_IFMT 0170000 bit mask for the file type bit fields
|
||||
S_IFMT 0170000 bit mask for the file type bit field
|
||||
|
||||
S_IFSOCK 0140000 socket
|
||||
S_IFLNK 0120000 symbolic link
|
||||
|
@ -424,14 +435,6 @@ S_IWOTH 00002 others have write permission
|
|||
S_IXOTH 00001 others have execute permission
|
||||
.TE
|
||||
.in
|
||||
.PP
|
||||
POSIX refers to the 12
|
||||
.I st_mode
|
||||
bits corresponding to the mask 07777 as the
|
||||
.IR "file mode bits"
|
||||
and the least significant 9 bits (00777)
|
||||
as the
|
||||
.IR "file permission bits" .
|
||||
.P
|
||||
The set-group-ID bit
|
||||
.RB ( S_ISGID )
|
||||
|
@ -650,7 +653,7 @@ According to POSIX.1-2001,
|
|||
.BR lstat ()
|
||||
on a symbolic link need return valid information only in the
|
||||
.I st_size
|
||||
field and the file-type component of the
|
||||
field and the file type of the
|
||||
.IR st_mode
|
||||
field of the
|
||||
.IR stat
|
||||
|
|
Loading…
Reference in New Issue