Allow prefix and prefix2 to be set to None to disable (useful if you

would rather bind the prefix in the root table).
This commit is contained in:
nicm
2015-12-12 18:19:00 +00:00
parent 88bc8f3528
commit 39cf9c9d31
10 changed files with 69 additions and 45 deletions

View File

@ -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);
}