mirror of
https://github.com/tmux/tmux.git
synced 2026-02-13 09:19:17 +00:00
Only loop over clients if table actually found, from Conor Taylor in
GitHub issue 4848.
This commit is contained in:
@@ -297,12 +297,12 @@ key_bindings_remove_table(const char *name)
|
|||||||
table = key_bindings_get_table(name, 0);
|
table = key_bindings_get_table(name, 0);
|
||||||
if (table != NULL) {
|
if (table != NULL) {
|
||||||
RB_REMOVE(key_tables, &key_tables, table);
|
RB_REMOVE(key_tables, &key_tables, table);
|
||||||
key_bindings_unref_table(table);
|
|
||||||
}
|
|
||||||
TAILQ_FOREACH(c, &clients, entry) {
|
TAILQ_FOREACH(c, &clients, entry) {
|
||||||
if (c->keytable == table)
|
if (c->keytable == table)
|
||||||
server_client_set_key_table(c, NULL);
|
server_client_set_key_table(c, NULL);
|
||||||
}
|
}
|
||||||
|
key_bindings_unref_table(table);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|||||||
Reference in New Issue
Block a user