GNU bug report logs - #43120
28.0.50; fido-mode: M-j before completions appear selects wrong choice

Previous Next

Package: emacs;

Reported by: Sean Whitton <spwhitton <at> spwhitton.name>

Date: Sun, 30 Aug 2020 21:01:01 UTC

Severity: normal

Tags: fixed

Merged with 43083

Found in version 28.0.50

Fixed in version 28.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Lars Ingebrigtsen <larsi <at> gnus.org>
To: Sean Whitton <spwhitton <at> spwhitton.name>
Cc: 43120 <at> debbugs.gnu.org, joaotavora <at> gmail.com
Subject: bug#43120: 28.0.50; fido-mode: M-j before completions appear selects wrong choice
Date: Fri, 04 Sep 2020 04:11:58 +0200
Sean Whitton <spwhitton <at> spwhitton.name> writes:

> The docstring for that function says it exits from a require-match
> minibuffer.  But completion gets used in other minibuffers too.  So we
> need to clear the variable somewhere which gets called for every
> minibuffer exit.

Yeah, following the exit logic (from the multiple number of code paths)
isn't trivial here.  But as far as I can tell, the exit-minibuffer
function is called in all the relevant code paths?

Does this fix the problem for you?

diff --git a/lisp/minibuffer.el b/lisp/minibuffer.el
index 864726e3cc..8984440576 100644
--- a/lisp/minibuffer.el
+++ b/lisp/minibuffer.el
@@ -2062,6 +2062,9 @@ exit-minibuffer
   ;; (or to turn it into a list of buffers, ...), but in the mean time,
   ;; this should do the trick in most cases.
   (setq deactivate-mark nil)
+  ;; Clear any computed default values (so that they're not used on
+  ;; the next invocation).
+  (setq completion-content-when-empty nil)
   (throw 'exit nil))
 
 (defun self-insert-and-exit ()

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no




This bug report was last modified 4 years and 311 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.