diff options
| author | Yuya Nishihara | 2012-12-01 21:25:13 +0800 |
|---|---|---|
| committer | Chong Yidong | 2012-12-01 21:25:13 +0800 |
| commit | cb5d51dc0707c3a55abb32ad09b747bc812c7b73 (patch) | |
| tree | 7e7fb80004b7318f430d32d3aed03dd3fc53f27a | |
| parent | ae067123d3f24430711973c24a8d2a8cfd33c1ef (diff) | |
| download | emacs-cb5d51dc0707c3a55abb32ad09b747bc812c7b73.tar.gz emacs-cb5d51dc0707c3a55abb32ad09b747bc812c7b73.zip | |
Fix use of buffer-file-truename in vc-find-file-hook (tiny change).
* lisp/vc/vc-hooks.el (vc-find-file-hook): Expand buffer-file-truename
before using it for comparison.
Fixes: debbugs:5297
| -rw-r--r-- | lisp/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/vc/vc-hooks.el | 5 |
2 files changed, 8 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c2e5e9fa8ce..ec7791597f0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,8 @@ | |||
| 1 | 2012-12-01 Yuya Nishihara <yuya@tcha.org> (tiny change) | ||
| 2 | |||
| 3 | * vc/vc-hooks.el (vc-find-file-hook): Expand buffer-file-truename | ||
| 4 | before using it for comparison (Bug#5297). | ||
| 5 | |||
| 1 | 2012-12-01 Jari Aalto <jari.aalto@cante.net> | 6 | 2012-12-01 Jari Aalto <jari.aalto@cante.net> |
| 2 | 7 | ||
| 3 | * textmodes/css-mode.el (css-current-defun-name): New function. | 8 | * textmodes/css-mode.el (css-current-defun-name): New function. |
diff --git a/lisp/vc/vc-hooks.el b/lisp/vc/vc-hooks.el index ef900cb5257..40a1f3db982 100644 --- a/lisp/vc/vc-hooks.el +++ b/lisp/vc/vc-hooks.el | |||
| @@ -858,8 +858,9 @@ current, and kill the buffer that visits the link." | |||
| 858 | (set (make-local-variable 'backup-inhibited) t)) | 858 | (set (make-local-variable 'backup-inhibited) t)) |
| 859 | ;; Let the backend setup any buffer-local things he needs. | 859 | ;; Let the backend setup any buffer-local things he needs. |
| 860 | (vc-call-backend backend 'find-file-hook)) | 860 | (vc-call-backend backend 'find-file-hook)) |
| 861 | ((let ((link-type (and (not (equal buffer-file-name buffer-file-truename)) | 861 | ((let* ((truename (expand-file-name buffer-file-truename)) |
| 862 | (vc-backend buffer-file-truename)))) | 862 | (link-type (and (not (equal buffer-file-name truename)) |
| 863 | (vc-backend truename)))) | ||
| 863 | (cond ((not link-type) nil) ;Nothing to do. | 864 | (cond ((not link-type) nil) ;Nothing to do. |
| 864 | ((eq vc-follow-symlinks nil) | 865 | ((eq vc-follow-symlinks nil) |
| 865 | (message | 866 | (message |