OSDN Git Service

LDP: Update original to LDP v3.79
[linuxjm/LDP_man-pages.git] / original / man2 / unlink.2
index 7aafb90..29d541b 100644 (file)
@@ -30,7 +30,7 @@
 .\" Modified 2001-05-17 by aeb
 .\" Modified 2004-06-23 by Michael Kerrisk <mtk.manpages@gmail.com>
 .\"
-.TH UNLINK 2 2014-02-21 "Linux" "Linux Programmer's Manual"
+.TH UNLINK 2 2014-08-19 "Linux" "Linux Programmer's Manual"
 .SH NAME
 unlink, unlinkat \- delete a name and possibly the file it refers to
 .SH SYNOPSIS
@@ -67,16 +67,16 @@ _ATFILE_SOURCE
 .BR unlink ()
 deletes a name from the filesystem.
 If that name was the
-last link to a file and no processes have the file open the file is
+last link to a file and no processes have the file open, the file is
 deleted and the space it was using is made available for reuse.
 
 If the name was the last link to a file but any processes still have
-the file open the file will remain in existence until the last file
+the file open, the file will remain in existence until the last file
 descriptor referring to it is closed.
 
-If the name referred to a symbolic link the link is removed.
+If the name referred to a symbolic link, the link is removed.
 
-If the name referred to a socket, fifo or device the name for it is
+If the name referred to a socket, FIFO, or device, the name for it is
 removed but processes which have the object open may continue to use
 it.
 .SS unlinkat()
@@ -278,6 +278,22 @@ SVr4, 4.3BSD, POSIX.1-2001, POSIX.1-2008.
 
 .BR unlinkat ():
 POSIX.1-2008.
+.SH NOTES
+.SS Glibc notes
+On older kernels where
+.BR unlinkat ()
+is unavailable, the glibc wrapper function falls back to the use of
+.BR unlink (2)
+or
+.BR rmdir (2).
+When
+.I pathname
+is a relative pathname,
+glibc constructs a pathname based on the symbolic link in
+.IR /proc/self/fd
+that corresponds to the
+.IR dirfd
+argument.
 .SH BUGS
 Infelicities in the protocol underlying NFS can cause the unexpected
 disappearance of files which are still being used.
@@ -293,3 +309,12 @@ disappearance of files which are still being used.
 .BR remove (3),
 .BR path_resolution (7),
 .BR symlink (7)
+.SH COLOPHON
+This page is part of release 3.79 of the Linux
+.I man-pages
+project.
+A description of the project,
+information about reporting bugs,
+and the latest version of this page,
+can be found at
+\%http://www.kernel.org/doc/man\-pages/.