aboutsummaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorStephen Gildea2019-12-20 09:15:13 -0800
committerStephen Gildea2019-12-21 10:51:10 -0800
commit678a71ea2d044f19f75e3f45c930c5e3b707e3dc (patch)
treee62c41f8970ff093717954d300f7176b8be2058c /doc
parent59ce7609cb383893ac55921589051993c388c6cc (diff)
downloademacs-678a71ea2d044f19f75e3f45c930c5e3b707e3dc.tar.gz
emacs-678a71ea2d044f19f75e3f45c930c5e3b707e3dc.zip
backup-by-copying-when-privileged-mismatch applies to file gid, too.
* lisp/files.el (backup-by-copying-when-privileged-mismatch): In addition to checking the file uid, a second test is added: if the file gid is not greater than backup-by-copying-when-privileged-mismatch, backup-by-copying-when-mismatch will also be forced on. * doc/emacs/files.texi, doc/lispref/backups.texi: Updated documentation. Also fixed a typo in the Emacs reference manual, changing "higher" to "no greater" so that the limit is no longer documented reversed.
Diffstat (limited to 'doc')
-rw-r--r--doc/emacs/files.texi5
-rw-r--r--doc/lispref/backups.texi6
2 files changed, 6 insertions, 5 deletions
diff --git a/doc/emacs/files.texi b/doc/emacs/files.texi
index 7221edcc1b2..f5dd408cc9f 100644
--- a/doc/emacs/files.texi
+++ b/doc/emacs/files.texi
@@ -690,8 +690,9 @@ non-@code{nil} (the default is @code{t}), and renaming would change
690the file's owner or group, use copying. 690the file's owner or group, use copying.
691 691
692If you change @code{backup-by-copying-when-mismatch} to @code{nil}, 692If you change @code{backup-by-copying-when-mismatch} to @code{nil},
693Emacs checks the numeric user-id of the file's owner. If this is 693Emacs checks the numeric user-id of the file's owner and the numeric
694higher than @code{backup-by-copying-when-privileged-mismatch}, then it 694group-id of the file's group. If either is
695no greater than @code{backup-by-copying-when-privileged-mismatch}, then it
695behaves as though @code{backup-by-copying-when-mismatch} is 696behaves as though @code{backup-by-copying-when-mismatch} is
696non-@code{nil} anyway. 697non-@code{nil} anyway.
697 698
diff --git a/doc/lispref/backups.texi b/doc/lispref/backups.texi
index 6a5b6d1661d..c17d98eb190 100644
--- a/doc/lispref/backups.texi
+++ b/doc/lispref/backups.texi
@@ -232,11 +232,11 @@ non-@code{nil}.
232@defopt backup-by-copying-when-privileged-mismatch 232@defopt backup-by-copying-when-privileged-mismatch
233This variable, if non-@code{nil}, specifies the same behavior as 233This variable, if non-@code{nil}, specifies the same behavior as
234@code{backup-by-copying-when-mismatch}, but only for certain user-id 234@code{backup-by-copying-when-mismatch}, but only for certain user-id
235values: namely, those less than or equal to a certain number. You set 235and group-id values: namely, those less than or equal to a certain number.
236this variable to that number. 236You set this variable to that number.
237 237
238Thus, if you set @code{backup-by-copying-when-privileged-mismatch} 238Thus, if you set @code{backup-by-copying-when-privileged-mismatch}
239to 0, backup by copying is done for the superuser only, 239to 0, backup by copying is done for the superuser and group 0 only,
240when necessary to prevent a change in the owner of the file. 240when necessary to prevent a change in the owner of the file.
241 241
242The default is 200. 242The default is 200.