# HG changeset patch # User Richard M. Stallman # Date 806100946 0 # Node ID a771c59393e7e7193803523f45dc82629a1e2a0b # Parent 9aaf593a2be2a50453bd86e3e9c1f9267f13e53e (vc-mode-line, vc-find-file-hook): Moved the test for version-controlled symbolic link from the former to the latter. diff -r 9aaf593a2be2 -r a771c59393e7 lisp/vc-hooks.el --- a/lisp/vc-hooks.el Tue Jul 18 20:52:39 1995 +0000 +++ b/lisp/vc-hooks.el Tue Jul 18 20:55:46 1995 +0000 @@ -746,13 +746,6 @@ (zerop (user-uid)) (not (equal (user-login-name) (vc-locking-user file))) (setq buffer-read-only t)) - (and (null vc-type) - (file-symlink-p file) - (let ((link-type (vc-backend (file-symlink-p file)))) - (if link-type - (message - "Warning: symbolic link to %s-controlled source file" - link-type)))) (force-mode-line-update) ;;(set-buffer-modified-p (buffer-modified-p)) ;;use this if Emacs 18 vc-type)) @@ -800,7 +793,13 @@ ;; Use this variable, not make-backup-files, ;; because this is for things that depend on the file name. (make-local-variable 'backup-inhibited) - (setq backup-inhibited t)))))))) + (setq backup-inhibited t)))) + ((let* ((link (file-symlink-p buffer-file-name)) + (link-type (and link (vc-backend link)))) + (if link-type + (message + "Warning: symbolic link to %s-controlled source file" + link-type)))))))) (add-hook 'find-file-hooks 'vc-find-file-hook)