(find-change-log): Use file-chase-links.

This commit is contained in:
Richard M. Stallman
1993-05-29 20:02:52 +00:00
parent 5dadeb297b
commit afb89aea69

View File

@@ -57,12 +57,8 @@ current buffer to the complete file name."
;; Chase links in the source file
;; and use the change log in the dir where it points.
(and buffer-file-name
(let (temp (file buffer-file-name))
(while (setq temp (file-symlink-p file))
(setq file
(expand-file-name
temp (file-name-directory file))))
(file-name-directory file)))
(file-name-directory
(file-chase-links buffer-file-name)))
default-directory)))
(if (and (eq file-name change-log-default-name)
(assq 'change-log-default-name (buffer-local-variables)))
@@ -74,10 +70,7 @@ current buffer to the complete file name."
;; Chase links before visiting the file.
;; This makes it easier to use a single change log file
;; for several related directories.
(let (temp)
(while (setq temp (file-symlink-p file-name))
(setq file-name
(expand-file-name temp (file-name-directory file-name)))))
(setq file-name (file-chase-links file-name))
(setq file-name (expand-file-name file-name))
;; Move up in the dir hierarchy till we find a change log file.
(let ((file1 file-name)