summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2013-03-25 11:44:16 +0000
committernicm <nicm@openbsd.org>2013-03-25 11:44:16 +0000
commit12a7017635956600048887bc28aa04c63608c27e (patch)
tree6a6da120c2a51e9dad3fae51f7565e62969e5968
parentAdd -P and -F to new-session. (diff)
downloadwireguard-openbsd-12a7017635956600048887bc28aa04c63608c27e.tar.xz
wireguard-openbsd-12a7017635956600048887bc28aa04c63608c27e.zip
Process ^[ as meta when a partial key is found.
-rw-r--r--usr.bin/tmux/tty-keys.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/tmux/tty-keys.c b/usr.bin/tmux/tty-keys.c
index aab045c4ea8..c31402d7d43 100644
--- a/usr.bin/tmux/tty-keys.c
+++ b/usr.bin/tmux/tty-keys.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: tty-keys.c,v 1.57 2013/03/25 11:36:25 nicm Exp $ */
+/* $OpenBSD: tty-keys.c,v 1.58 2013/03/25 11:44:16 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -498,6 +498,7 @@ tty_keys_next(struct tty *tty)
goto complete_key;
}
+first_key:
/* Is this a meta key? */
if (len >= 2 && buf[0] == '\033') {
if (buf[1] != '\033') {
@@ -518,7 +519,6 @@ tty_keys_next(struct tty *tty)
}
}
-first_key:
/* No key found, take first. */
key = (u_char) *buf;
size = 1;