diff options
author | 2010-03-22 19:03:52 +0000 | |
---|---|---|
committer | 2010-03-22 19:03:52 +0000 | |
commit | 2d9c2cb9e339fc14fc61622a31862358a5c509cc (patch) | |
tree | 6891d42f7b142a1f878585b9cbbc0c9bdfde2e99 | |
parent | New input parser based on http://vt100.net/emu/dec_ansi_parser. (diff) | |
download | wireguard-openbsd-2d9c2cb9e339fc14fc61622a31862358a5c509cc.tar.xz wireguard-openbsd-2d9c2cb9e339fc14fc61622a31862358a5c509cc.zip |
Accept a full key match (not a partial) even if there is data left in
the buffer.
-rw-r--r-- | usr.bin/tmux/tty-keys.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/tmux/tty-keys.c b/usr.bin/tmux/tty-keys.c index 3a3057fda85..2e12e42dc69 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.29 2009/12/17 17:39:56 nicm Exp $ */ +/* $OpenBSD: tty-keys.c,v 1.30 2010/03/22 19:03:52 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net> @@ -408,7 +408,7 @@ tty_keys_find1(struct tty_key *tk, const char *buf, size_t len, size_t *size) (*size)++; /* At the end of the string, return the current node. */ - if (len == 0) + if (len == 0 || (tk->next == NULL && tk->key != KEYC_NONE)) return (tk); /* Move into the next tree for the following character. */ |