fix: don't insert any unhandled control keys

pull/143/head
TorchedSammy 2022-04-13 19:36:18 -04:00
parent e5c9b85008
commit 194e4e01b7
Signed by: sammyette
GPG Key ID: 904FC49417B44DCD
2 changed files with 2 additions and 3 deletions

View File

@ -34,7 +34,6 @@ const (
charCtrlHat // ^^
charCtrlUnderscore // ^_
charBackspace2 = 127 // ASCII 1963
)
// Escape sequences

View File

@ -557,8 +557,8 @@ func (rl *Instance) editorInput(r []rune) {
rl.refreshVimStatus()
default:
// For some reason Ctrl+k messes with the input line, so ignore it.
if r[0] == 11 {
// Don't insert control keys
if r[0] >= 1 && r[0] <= 31 {
return
}
// We reset the history nav counter each time we come here: