summaryrefslogtreecommitdiff
path: root/doc/lispref/files.texi
diff options
context:
space:
mode:
Diffstat (limited to 'doc/lispref/files.texi')
-rw-r--r--doc/lispref/files.texi14
1 files changed, 12 insertions, 2 deletions
diff --git a/doc/lispref/files.texi b/doc/lispref/files.texi
index e36fdbe95bf..a692bb2f2b6 100644
--- a/doc/lispref/files.texi
+++ b/doc/lispref/files.texi
@@ -712,6 +712,7 @@ with-temp-buffer,, The Current Buffer}.
@section File Locks
@cindex file locks
@cindex lock file
+@cindex .#, lock file names
When two users edit the same file at the same time, they are likely
to interfere with each other. Emacs tries to prevent this situation
@@ -720,8 +721,17 @@ modified.
Emacs can then detect the first attempt to modify a buffer visiting a
file that is locked by another Emacs job, and ask the user what to do.
The file lock is really a file, a symbolic link with a special name,
-stored in the same directory as the file you are editing. (On file
-systems that do not support symbolic links, a regular file is used.)
+stored in the same directory as the file you are editing. The name is
+constructed by prepending @file{.#} to the filename of the buffer.
+The target of the symbolic link will be of the form
+@code{@var{user}@@@var{host}.@var{pid}:@var{boot}}, where @var{user}
+is replaced with the current username (from @code{user-login-name}),
+@var{host} with the name of the host where Emacs is running (from
+@code{system-name}), @var{pid} with Emacs's process id, and @var{boot}
+with the time since the last reboot. @code{:@var{boot}} is omitted if
+the boot time is unavailable. (On file systems that do not support
+symbolic links, a regular file is used instead, with contents of the
+form @code{@var{user}@@@var{host}.@var{pid}:@var{boot}}.)
When you access files using NFS, there may be a small probability that
you and another user will both lock the same file simultaneously.