From 0c16bb5a39b38c48374bc3ad4ca99208ff329d46 Mon Sep 17 00:00:00 2001 From: Alexander Gramiak Date: Tue, 2 Apr 2019 11:14:18 -0600 Subject: [PATCH] * lisp/frame.el (display-planes): Use logb over truncate + log Suggested by Basil L. Contovounesios: https://lists.gnu.org/archive/html/bug-gnu-emacs/2019-03/msg01052.html --- lisp/frame.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/frame.el b/lisp/frame.el index aa14e87d7b8..b39891cd142 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -2093,7 +2093,7 @@ If DISPLAY is omitted or nil, it defaults to the selected frame's display." ((eq frame-type 'pc) 4) (t - (truncate (log (length (tty-color-alist)) 2)))))) + (logb (length (tty-color-alist))))))) (declare-function x-display-color-cells "xfns.c" (&optional terminal)) -- 2.39.2