mirror of
https://github.com/tmux/tmux.git
synced 2025-09-02 13:37:12 +00:00
Validate command argument types (string or command list) and give more
useful error messages.
This commit is contained in:
@ -634,8 +634,10 @@ key_bindings_init(void)
|
||||
|
||||
for (i = 0; i < nitems(defaults); i++) {
|
||||
pr = cmd_parse_from_string(defaults[i], NULL);
|
||||
if (pr->status != CMD_PARSE_SUCCESS)
|
||||
if (pr->status != CMD_PARSE_SUCCESS) {
|
||||
log_debug("%s", pr->error);
|
||||
fatalx("bad default key: %s", defaults[i]);
|
||||
}
|
||||
cmdq_append(NULL, cmdq_get_command(pr->cmdlist, NULL));
|
||||
cmd_list_free(pr->cmdlist);
|
||||
}
|
||||
|
Reference in New Issue
Block a user