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

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

[nongnu] elpa/annotate ce49471b20 05/13: - returned nil as the actual fi


From: ELPA Syncer
Subject: [nongnu] elpa/annotate ce49471b20 05/13: - returned nil as the actual filename of an indirect buffer.
Date: Fri, 16 Sep 2022 11:58:22 -0400 (EDT)

branch: elpa/annotate
commit ce49471b203b55099630573b0c0962a8316a3628
Author: cage <cage>
Commit: cage <cage@invalid>

    - returned nil as the actual filename of an indirect buffer.
---
 annotate.el | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/annotate.el b/annotate.el
index a9558eeda1..d8aa990317 100644
--- a/annotate.el
+++ b/annotate.el
@@ -1329,12 +1329,19 @@ text will be discarded."
 buffer is not on info-mode"
   (annotate-guess-filename-for-dump Info-current-file nil))
 
+(cl-defun annotate-indirect-buffer-p (&optional (buffer (current-buffer)))
+  (buffer-base-buffer buffer))
+
 (defun annotate-actual-file-name ()
   "Get the actual file name of the current buffer."
-  (substring-no-properties (or (annotate-info-actual-filename)
-                               (buffer-file-name)
-                               (buffer-file-name (buffer-base-buffer))
-                               "")))
+  (cond
+   ((annotate-indirect-buffer-p)
+    nil)
+   (t
+    (substring-no-properties (or (annotate-info-actual-filename)
+                                 (buffer-file-name)
+                                 (buffer-file-name (buffer-base-buffer))
+                                 "")))))
 
 (cl-defun annotate-guess-filename-for-dump (filename
                                             &optional 
(return-filename-if-not-found-p t))



reply via email to

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