[Top][All Lists]

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

master 2bd1b1a: Fix dired--insert-disk-space

From: Michael Albinus
Subject: master 2bd1b1a: Fix dired--insert-disk-space
Date: Fri, 3 Dec 2021 09:50:17 -0500 (EST)

branch: master
commit 2bd1b1ace8281c92d74e9eb14dc39210517949fa
Author: Michael Albinus <michael.albinus@gmx.de>
Commit: Michael Albinus <michael.albinus@gmx.de>

    Fix dired--insert-disk-space
    * lisp/dired.el (dired--insert-disk-space): Handle case
    `get-free-disk-space' returns nil.
 lisp/dired.el | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lisp/dired.el b/lisp/dired.el
index d03c79d..d0e547b 100644
--- a/lisp/dired.el
+++ b/lisp/dired.el
@@ -1650,7 +1650,7 @@ see `dired-use-ls-dired' for more details.")
         ;; Replace "total" with "total used in directory" to
         ;; avoid confusion.
         (replace-match "total used in directory" nil nil nil 1))
-      (when-let ((available (get-free-disk-space file)))
+      (if-let ((available (get-free-disk-space file)))
          ((eq dired-free-space 'separate)
@@ -1672,7 +1672,8 @@ see `dired-use-ls-dired' for more details.")
           (forward-line 1)
-          beg))))))
+          beg))
+        beg))))
 (defun dired-insert-set-properties (beg end)
   "Add various text properties to the lines in the region, from BEG to END."

reply via email to

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