diff options
Diffstat (limited to 'usr.bin/tmux/cmd-send-keys.c')
-rw-r--r-- | usr.bin/tmux/cmd-send-keys.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/usr.bin/tmux/cmd-send-keys.c b/usr.bin/tmux/cmd-send-keys.c index 2d602bac226..bafeff05931 100644 --- a/usr.bin/tmux/cmd-send-keys.c +++ b/usr.bin/tmux/cmd-send-keys.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cmd-send-keys.c,v 1.42 2017/06/28 11:36:39 nicm Exp $ */ +/* $OpenBSD: cmd-send-keys.c,v 1.43 2018/08/02 11:44:07 nicm Exp $ */ /* * Copyright (c) 2008 Nicholas Marriott <nicholas.marriott@gmail.com> @@ -61,7 +61,7 @@ cmd_send_keys_inject(struct client *c, struct cmdq_item *item, key_code key) struct window_pane *wp = item->target.wp; struct session *s = item->target.s; struct key_table *table; - struct key_binding *bd, bd_find; + struct key_binding *bd; if (wp->mode == NULL || wp->mode->key_table == NULL) { if (options_get_number(wp->window->options, "xterm-keys")) @@ -71,8 +71,7 @@ cmd_send_keys_inject(struct client *c, struct cmdq_item *item, key_code key) } table = key_bindings_get_table(wp->mode->key_table(wp), 1); - bd_find.key = (key & ~KEYC_XTERM); - bd = RB_FIND(key_bindings, &table->key_bindings, &bd_find); + bd = key_bindings_get(table, key & ~KEYC_XTERM); if (bd != NULL) { table->references++; key_bindings_dispatch(bd, item, c, NULL, &item->target); |