emacs-diffs
[Top][All Lists]
Advanced

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

master 21e1a12: Make memory-report work with buffer-local unbound vars


From: Lars Ingebrigtsen
Subject: master 21e1a12: Make memory-report work with buffer-local unbound vars
Date: Thu, 18 Mar 2021 03:33:48 -0400 (EDT)

branch: master
commit 21e1a126b54390b5a22e5af836d14ae8f4e423fb
Author: Lars Ingebrigtsen <larsi@gnus.org>
Commit: Lars Ingebrigtsen <larsi@gnus.org>

    Make memory-report work with buffer-local unbound vars
    
    * lisp/emacs-lisp/memory-report.el (memory-report--buffer-data):
    Protect against buffer-local unbound variables (bug#47057).
---
 lisp/emacs-lisp/memory-report.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/emacs-lisp/memory-report.el b/lisp/emacs-lisp/memory-report.el
index 3d6ca95..ecbca28 100644
--- a/lisp/emacs-lisp/memory-report.el
+++ b/lisp/emacs-lisp/memory-report.el
@@ -295,7 +295,7 @@ by counted more than once."
               (- (position-bytes (point-min)))
               (gap-size)))
           (seq-reduce #'+ (mapcar (lambda (elem)
-                                    (if (cdr elem)
+                                    (if (and (consp elem) (cdr elem))
                                         (memory-report--object-size
                                          (make-hash-table :test #'eq)
                                          (cdr elem))



reply via email to

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