;;; userlock.el --- handle file access contention between multiple users
-;; Copyright (C) 1985, 1986 Free Software Foundation, inc.
+;; Copyright (C) 1985, 1986, 2002, 2003, 2004,
+;; 2005, 2006 Free Software Foundation, Inc.
;; Maintainer: FSF
;; Keywords: internal
;; You should have received a copy of the GNU General Public License
;; along with GNU Emacs; see the file COPYING. If not, write to the
-;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
-;; Boston, MA 02111-1307, USA.
+;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
+;; Boston, MA 02110-1301, USA.
;;; Commentary:
(defun ask-user-about-lock (file opponent)
"Ask user what to do when he wants to edit FILE but it is locked by OPPONENT.
This function has a choice of three things to do:
- do (signal 'buffer-file-locked (list FILE OPPONENT))
+ do (signal 'file-locked (list FILE OPPONENT))
to refrain from editing the file
return t (grab the lock on the file)
return nil (edit the file even though it is locked).
(message "%s changed on disk; really edit the buffer? (y, n, r or C-h) "
(file-name-nondirectory fn))
(let ((tem (downcase (let ((cursor-in-echo-area t))
- (read-char)))))
+ (read-char-exclusive)))))
(setq answer
(if (= tem help-char)
'help
(set-buffer standard-output)
(help-mode))))
+;;; arch-tag: a61c5b60-e1c8-44fd-894a-c617f4dfc639
;;; userlock.el ends here