less icon indicating copy to clipboard operation
less copied to clipboard

Erroneous behavior if partial command is followed by another command

Open gwsw opened this issue 1 year ago • 1 comments

Steps to reproduce:

  1. Run less in an xterm window.
  2. Enter G.
  3. Enter :.
  4. Press HOME.

Expected: The : should be ignored and the HOME key should jump to the start of the file.

Actual: The help file is opened.

Explanation: On an xterm, HOME maps to "\eOH". When less sees the sequence ":\e" it treats it as a bad command and discards both characters. Then it processes the "O" and the "H" as separate commands.

Discovered while investigating #523.

gwsw avatar Jul 09 '24 23:07 gwsw

Should be fixed in 6a6aa61f75ecfdded373ac0c49e21764d7ae7dad.

gwsw avatar Jul 10 '24 16:07 gwsw