From a31be116aeee43b7a2e14d53db226933d4e8a012 Mon Sep 17 00:00:00 2001 From: Juri Linkov Date: Sun, 20 Mar 2022 20:59:04 +0200 Subject: [PATCH] * lisp/tab-bar.el (tab-bar-new-tab-to): Don't funcall const values. Filter out the values 'clone' and 'window' of 'tab-bar-new-tab-choice' from function call. --- lisp/tab-bar.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/tab-bar.el b/lisp/tab-bar.el index 245a55a671f..cf1cca4af3f 100644 --- a/lisp/tab-bar.el +++ b/lisp/tab-bar.el @@ -1384,7 +1384,8 @@ After the tab is created, the hooks in (split-window) (delete-window)))) (let ((buffer - (if (functionp tab-bar-new-tab-choice) + (if (and (functionp tab-bar-new-tab-choice) + (not (memq tab-bar-new-tab-choice '(clone window)))) (funcall tab-bar-new-tab-choice) (if (stringp tab-bar-new-tab-choice) (or (get-buffer tab-bar-new-tab-choice) -- 2.39.2