diff options
author | nicm <nicm> | 2017-09-08 08:45:27 +0000 |
---|---|---|
committer | nicm <nicm> | 2017-09-08 08:45:27 +0000 |
commit | 78cf3c14ca44bbbebd3fcb374c0397c72caf6c78 (patch) | |
tree | 442f44a34f2d2f26df4e92b43b5bda7db89862dd | |
parent | 89e057dc4a8410207d3888e901eb3a3062002190 (diff) | |
download | rtmux-78cf3c14ca44bbbebd3fcb374c0397c72caf6c78.tar.gz rtmux-78cf3c14ca44bbbebd3fcb374c0397c72caf6c78.tar.bz2 rtmux-78cf3c14ca44bbbebd3fcb374c0397c72caf6c78.zip |
When removing a key table clear it out of clients, fixes issue with
unbind -a reported by Thomas Sattler.
-rw-r--r-- | key-bindings.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/key-bindings.c b/key-bindings.c index 39083af0..badbc0f4 100644 --- a/key-bindings.c +++ b/key-bindings.c @@ -138,12 +138,17 @@ void key_bindings_remove_table(const char *name) { struct key_table *table; + struct client *c; table = key_bindings_get_table(name, 0); if (table != NULL) { RB_REMOVE(key_tables, &key_tables, table); key_bindings_unref_table(table); } + TAILQ_FOREACH(c, &clients, entry) { + if (c->keytable == table) + server_client_set_key_table(c, NULL); + } } void |