Ticket #3651 (closed defect: duplicate)
keypad 5 input freeze
Reported by: | igor2 | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | |
Component: | mc-tty | Version: | 4.8.17 |
Keywords: | keypad KP_5 KP_BEGIN freeze escape sequence terminal control | Cc: | |
Blocked By: | Blocking: | ||
Branch state: | no branch | Votes for changeset: |
Description
Pressing keypad 5 (while numlock is off) on the linux console or on xterm makes mc stop reading the input for a second or two.
Cause: unrecognized escape sequence - mc tries to read (using timed reads) until the sequence is over.
Proposed solution: teach mc KP_5 (some sources call it KP_BEGIN or KP_CLEAR). I tried to add it in /usr/share/mc/mc.lib but that didn't work. Sequence on the Linux console on PC:
e[G and on xterm:
e[E
As a test I applied the patch attached - it is probably not the proper solution but fixed the problem for me on the console.
mc version affected: 4.8.15, 4.8.17; I think this problem was not present in the 4.7 series.
GNU Midnight Commander 4.8.15 Built with GLib 2.46.2 Using the S-Lang library with terminfo database With builtin Editor With subshell support as default With support for background operations With mouse support on xterm and Linux console With support for X11 events With internationalization support With multiple codepages support Virtual File Systems: cpiofs, tarfs, sfs, extfs, ext2undelfs, ftpfs, sftpfs, fish Data types: char: 8; int: 32; long: 64; void *: 64; size_t: 64; off_t: 64;
proof of concept patch for the Linux console (workaround)