Skip to content

Commit

Permalink
magit-revert-buffers: compare truenames
Browse files Browse the repository at this point in the history
See #1545.
  • Loading branch information
tarsius committed Oct 13, 2014
1 parent febc832 commit 140e823
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions magit.el
Expand Up @@ -4080,8 +4080,10 @@ the current repository."
(tracked (magit-git-lines "ls-tree" "-r" "--name-only" "HEAD")))
(dolist (buf (buffer-list))
(with-current-buffer buf
(let ((file (buffer-file-name)))
(when (and file (string-prefix-p topdir file)
(let ((file buffer-file-truename))
(when (and file
(setq file (expand-file-name file))
(string-prefix-p topdir file)
(not (string-prefix-p gitdir file))
(member (file-relative-name file topdir) tracked)
(file-readable-p file)
Expand Down

0 comments on commit 140e823

Please sign in to comment.