nano

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

commit 4ef4eb4f120b9da689172b1c7f41136a574c3102
parent 862574f3817abe66a116d3371337f6a3115c2d76
Author: Benno Schulenberg <bensberg@telfort.nl>
Date:   Fri,  8 Mar 2024 11:04:48 +0100

options: make --modernbindings actually override --preserve

When modern bindings are requested, ^S should save and ^Q must exit,
so --preserve and 'set preserve' need to be cancelled.

This fixes https://savannah.gnu.org/bugs/?65433.

Bug existed since commit 18b37c98, which introduced --modernbindings.

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

diff --git a/src/nano.c b/src/nano.c @@ -2253,6 +2253,10 @@ int main(int argc, char **argv) if (ISSET(RAW_SEQUENCES)) UNSET(USE_MOUSE); + /* When --modernbindings is used, ^Q and ^S need to be functional. */ + if (ISSET(MODERN_BINDINGS)) + UNSET(PRESERVE); + /* When suppressing title bar or minibar, suppress also the help lines. */ if (ISSET(ZERO)) SET(NO_HELP);