From f596be99505a0191cac9f314fb1b71528c5080b4 Mon Sep 17 00:00:00 2001 From: Nicholas Marriott Date: Tue, 28 Jul 2009 17:05:10 +0000 Subject: Final pieces of mode key rebinding: bind-key and unbind-key now accept a -t argument to modify a table. --- cmd-list-keys.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'cmd-list-keys.c') diff --git a/cmd-list-keys.c b/cmd-list-keys.c index 0a22e82c..db64e244 100644 --- a/cmd-list-keys.c +++ b/cmd-list-keys.c @@ -92,11 +92,7 @@ cmd_list_keys_table(struct cmd *self, struct cmd_ctx *ctx) const char *key, *cmdstr, *mode; int width, keywidth; - for (mtab = mode_key_tables; mtab->name != NULL; mtab++) { - if (strcasecmp(data->target, mtab->name) == 0) - break; - } - if (mtab->name == NULL) { + if ((mtab = mode_key_findtable(data->target)) == NULL) { ctx->error(ctx, "unknown key table: %s", data->target); return (-1); } -- cgit v1.2.3