Merge branch 'obsd-master'

This commit is contained in:
Thomas Adam 2018-10-28 16:02:37 +00:00
commit 0a54a07909
1 changed files with 1 additions and 1 deletions

View File

@ -624,7 +624,7 @@ first_key:
* If not a complete key, look for key with an escape prefix (meta
* modifier).
*/
if (*buf == '\033') {
if (*buf == '\033' && len > 1) {
/* Look for a key without the escape. */
n = tty_keys_next1(tty, buf + 1, len - 1, &key, &size, expired);
if (n == 0) { /* found */