summaryrefslogtreecommitdiffstats
path: root/usr.bin/tmux/cmd-set-option.c
diff options
context:
space:
mode:
authornicm <nicm@openbsd.org>2015-12-12 18:19:00 +0000
committernicm <nicm@openbsd.org>2015-12-12 18:19:00 +0000
commit0bd9fd8f2d4f4289ee483c71331058cc126d71aa (patch)
tree9ae5e6c75ba58ca271fce73b7dc54991e2feb713 /usr.bin/tmux/cmd-set-option.c
parentcorrect comment (diff)
downloadwireguard-openbsd-0bd9fd8f2d4f4289ee483c71331058cc126d71aa.tar.xz
wireguard-openbsd-0bd9fd8f2d4f4289ee483c71331058cc126d71aa.zip
Allow prefix and prefix2 to be set to None to disable (useful if you
would rather bind the prefix in the root table).
Diffstat (limited to 'usr.bin/tmux/cmd-set-option.c')
-rw-r--r--usr.bin/tmux/cmd-set-option.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/tmux/cmd-set-option.c b/usr.bin/tmux/cmd-set-option.c
index b6a26b05b68..de9ab40a971 100644
--- a/usr.bin/tmux/cmd-set-option.c
+++ b/usr.bin/tmux/cmd-set-option.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cmd-set-option.c,v 1.87 2015/11/20 12:01:19 nicm Exp $ */
+/* $OpenBSD: cmd-set-option.c,v 1.88 2015/12/12 18:19:00 nicm Exp $ */
/*
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
@@ -396,7 +396,8 @@ cmd_set_option_key(__unused struct cmd *self, struct cmd_q *cmdq,
{
key_code key;
- if ((key = key_string_lookup_string(value)) == KEYC_NONE) {
+ key = key_string_lookup_string(value);
+ if (key == KEYC_UNKNOWN) {
cmdq_error(cmdq, "bad key: %s", value);
return (NULL);
}