summaryrefslogtreecommitdiff
path: root/lisp/emacs-lisp/memory-report.el
diff options
context:
space:
mode:
authorAndrea Corallo <akrl@sdf.org>2020-12-13 01:11:56 +0100
committerAndrea Corallo <akrl@sdf.org>2020-12-13 11:09:20 +0100
commit831659b3b88d42ea5e4adab2be3316cfffa2efd1 (patch)
tree8c06541098b55f7f4531b09342fb62e0ec301796 /lisp/emacs-lisp/memory-report.el
parent2d790c6c57b244447390c023679752243e0049c9 (diff)
downloademacs-831659b3b88d42ea5e4adab2be3316cfffa2efd1.tar.gz
emacs-831659b3b88d42ea5e4adab2be3316cfffa2efd1.tar.bz2
emacs-831659b3b88d42ea5e4adab2be3316cfffa2efd1.zip
* Fix `memory-report' for '--without-x' builds
* lisp/emacs-lisp/memory-report.el (memory-report--image-cache): Don't call `image-cache-size' if unbound.
Diffstat (limited to 'lisp/emacs-lisp/memory-report.el')
-rw-r--r--lisp/emacs-lisp/memory-report.el4
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/emacs-lisp/memory-report.el b/lisp/emacs-lisp/memory-report.el
index c88d9f2768a..04ae87d9ea0 100644
--- a/lisp/emacs-lisp/memory-report.el
+++ b/lisp/emacs-lisp/memory-report.el
@@ -294,7 +294,9 @@ by counted more than once."
(overlay-lists)))))
(defun memory-report--image-cache ()
- (list (cons "Total Image Cache Size" (image-cache-size))))
+ (list (cons "Total Image Cache Size" (if (fboundp 'image-cache-size)
+ (image-cache-size)
+ 0))))
(provide 'memory-report)