I found a bug.  If you bind any Ctrl prefixed combination to help and
press any unbound key, km_error_key() prints just "Key is not bound."

For example, after defining this:

 :bind index \Ch help
 :bind index l noop

If in the index you press 'l' you have the following message:

 Key is not bound.

When it should print:

 Key is not bound.  Press '^H' for help.


Doing the same in the pager produces and infinite loop.  Something alike
the described here:

https://marc.info/?l=mutt-dev&m=146365169501329&w=2

but this time with Control prefixed bindings.


I tried to investigate the cause but my level of C doesn't help.
The problem is in these lines of km_error_key() on keymap.c:

 /* make sure the key is really the help key in this menu */
 tokenize_unget_string (buf);
 if (km_dokey (menu) != OP_HELP)
 {
   mutt_error _("Key is not bound.");
   return;
 }

I'm not able to understand what this check do and why, the fact is if I
compile mutt without these lines the problem is gone and all works as
expected (is really useful that check?).  Guessing from my bare
intuition, the functions tokenize_unget_string() and km_dokey() aren't
able to parse Ctrl prefixed bindings.

Reply via email to