bugGNU nano - Bugs: bug #55442, one or two Escapes followed by a...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #55442: one or two Escapes followed by a shifted Meta+letter isn't parsed correctly

Submitted by:  David Lawrence Ramsey <dolorous>
Submitted on:  Thu 10 Jan 2019 06:21:25 PM UTC  
 
Severity:  2 - Minor Status:  Fixed
Assigned to:  David Lawrence Ramsey <dolorous> Open/Closed:  Closed

Fri 08 Feb 2019 07:14:46 PM UTC, comment #5: 

(Forgot to reply here.)

Thank you.

As for the other statement, you've complained about other bits of code being obscure before (as in, "no one's going to do that"); I was merely trying to get a better example in order to preemptively avoid that.

(To be perfectly blunt, If I were actually trying to be condescending, I would phrase things differently, and be much more obvious about it.  Kindly stop reading things into what I and others say that aren't actually there.)

David Lawrence Ramsey <dolorous>
Project MemberIn charge of this item.
Tue 15 Jan 2019 06:51:23 PM UTC, comment #4: 

Fixed in git, commit 194d1858.

Benno Schulenberg <bens>
Project Administrator
Mon 14 Jan 2019 07:42:21 PM UTC, comment #3: 

"And in case you think..."  Grrr!  Go away with your condescending remarks!!

Benno Schulenberg <bens>
Project Administrator
Thu 10 Jan 2019 07:21:53 PM UTC, comment #2: 

And in case you think the way to trigger the bug is too obscure, it can be triggered more commonly via Caps Lock.

1. Turn on Caps Lock, press Escape, and then press Alt+G.  Unpatched nano gives you "Unbound key "M-G".

2. Turn on Caps Lock, press Escape, press Escape, and then press Alt+G.  Unpatched nano gives you "Unbound key "M-G".

Both of those work properly in unpatched nano when Caps Lock is off.

David Lawrence Ramsey <dolorous>
Project MemberIn charge of this item.
Thu 10 Jan 2019 06:23:10 PM UTC, comment #1: 

The attached patches against git 0ae80ce fix this.

(file #45930, file #45931)

David Lawrence Ramsey <dolorous>
Project MemberIn charge of this item.
Thu 10 Jan 2019 06:21:25 PM UTC, original submission:  

Specifically, there's an inconsistency between how Meta+[letter] is handled and how Esc Meta+[letter] and Esc Esc Meta+[letter] are handled.

The problem occurs when you're using the shift key with [letter].  For example, say that the letter is G.

Meta+Shift+G acts the same as Meta+G, as expected.
Esc Meta+Shift+G produces: Unbound key "M-G"
Esc Esc Meta+Shift+G produces: Unbound key "M-G"

This has been broken since commit ecc9211.  It was intended to ignore all previous escapes if a meta sequence was read, but it doesn't set the returned value to lowercase as the other meta sequence reader does.  Without that, nano tries to distinguish between Meta-G and Meta-g in the latter cases, and fails since it only understands Meta-g.

David Lawrence Ramsey <dolorous>
Project MemberIn charge of this item.

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bens (Posted a comment)
  • -email is unavailable- added by dolorous (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follow 7 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-03-25 bens Open/ClosedOpen => Closed
    2019-01-15 bens StatusNone => Fixed
        Assigned toNone => dolorous
    2019-01-14 bens Severity3 - Normal => 2 - Minor
        SummaryEscapes followed by shifted letter keys aren't parsed correctly => one or two Escapes followed by a shifted Meta+letter isn't parsed correctly
    2019-01-10 dolorous Attached File- => Added 0001-input-properly-handle-escapes-followed-by-shifted-si.patch, #45930
        Attached File- => Added 0002-tweaks-fix-indentation-after-last-commit.patch, #45931

    Back to the top


    Powered by Savane 3.5