nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit 2157738a184b3dda9a8228ece6b630a28a4aca13
parent 681d11c0cf626c158b400d0fedd7fd8bc3526467
Author: Benno Schulenberg <bensberg@telfort.nl>
Date:   Fri,  4 Dec 2020 17:03:10 +0100

tweaks: correct two comments after the previous changes

Diffstat:
Msrc/winio.c | 8++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/winio.c b/src/winio.c @@ -903,8 +903,8 @@ int parse_kbinput(WINDOW *win) if (keycode == ERR) return ERR; - /* Remember whether an Esc arrived by itself, and increment - * its counter, rolling around on three escapes. */ + /* For an Esc, remember whether the last two arrived by themselves. + * Then increment the counter, rolling around on three escapes. */ if (keycode == ESC_CODE) { first_escape_was_alone = last_escape_was_alone; last_escape_was_alone = (key_buffer_len == 0); @@ -998,8 +998,8 @@ int parse_kbinput(WINDOW *win) else return byte; } else if (digit_count == 0) { - /* If the second escape did not arrive alone, it is a Meta - * keystroke; otherwise, it is an "Esc Esc control". */ + /* If the first escape arrived alone but not the second, then it + * is a Meta keystroke; otherwise, it is an "Esc Esc control". */ if (first_escape_was_alone && !last_escape_was_alone) { if (!shifted_metas) keycode = tolower(keycode);