diff options
Diffstat (limited to 'share/man/man4/unix.4')
-rw-r--r-- | share/man/man4/unix.4 | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/share/man/man4/unix.4 b/share/man/man4/unix.4 index 5ac9ccd5514f..2fdfde225b14 100644 --- a/share/man/man4/unix.4 +++ b/share/man/man4/unix.4 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd February 1, 2022 +.Dd October 31, 2024 .Dt UNIX 4 .Os .Sh NAME @@ -77,6 +77,15 @@ removed when the socket is closed \(em .Xr unlink 2 must be used to remove the file. .Pp +Prior to binding a socket, +.Xr fchmod 2 +can be used to set the permissions of the socket file. +This avoids the race that would otherwise occur between creation of the file +and a subsequent call to +.Xr chmod 2 . +Once the socket is bound to a file name, the permissions of the file can not be +changed this way. +.Pp The length of .Ux Ns -domain address, required by @@ -441,6 +450,7 @@ The order is preserved for writes coming through a particular connection. .Sh SEE ALSO .Xr connect 2 , .Xr dup 2 , +.Xr fchmod 2 , .Xr fcntl 2 , .Xr getsockopt 2 , .Xr listen 2 , |