emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/vlf bb482f0 173/310: Fix file size determination for sy


From: Stefan Monnier
Subject: [elpa] externals/vlf bb482f0 173/310: Fix file size determination for symbolic links.
Date: Sat, 28 Nov 2020 00:33:09 -0500 (EST)

branch: externals/vlf
commit bb482f0b0f0c777a04e17864bc38634837d359d9
Author: Andrey Kotlarski <m00naticus@gmail.com>
Commit: Andrey Kotlarski <m00naticus@gmail.com>

    Fix file size determination for symbolic links.
---
 vlf.el | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/vlf.el b/vlf.el
index 8ee013d..8d0eca5 100644
--- a/vlf.el
+++ b/vlf.el
@@ -192,13 +192,11 @@ You can customize number of bytes displayed by customizing
           (if (memq system-type '(windows-nt cygwin))
               ;; System is case-insensitive.
               (let ((case-fold-search t))
-                (assoc-default name auto-mode-alist
-                               'string-match))
+                (assoc-default name auto-mode-alist 'string-match))
             ;; System is case-sensitive.
             (or ;; First match case-sensitively.
              (let ((case-fold-search nil))
-               (assoc-default name auto-mode-alist
-                              'string-match))
+               (assoc-default name auto-mode-alist 'string-match))
              ;; Fallback to case-insensitive match.
              (and auto-mode-case-fold
                   (let ((case-fold-search t))
@@ -297,7 +295,7 @@ with the prefix argument DECREASE it is halved."
 
 (defun vlf-get-file-size (file)
   "Get size in bytes of FILE."
-  (or (nth 7 (file-attributes file)) 0))
+  (or (nth 7 (file-attributes (file-truename file))) 0))
 
 (defun vlf-verify-size ()
   "Update file size information if necessary and visited file time."



reply via email to

[Prev in Thread] Current Thread [Next in Thread]