Use key_bindings_remove for unbind-key -a to allow it to work from key

bindings. From "miaout17" SF bug 3392063.
pull/1/head
Nicholas Marriott 2011-08-16 09:37:48 +00:00
parent 6b734d1074
commit 2fc84c7c34
1 changed files with 1 additions and 3 deletions

View File

@ -59,9 +59,7 @@ cmd_unbind_key_exec(struct cmd *self, unused struct cmd_ctx *ctx)
if (args_has(args, 'a')) {
while (!SPLAY_EMPTY(&key_bindings)) {
bd = SPLAY_ROOT(&key_bindings);
SPLAY_REMOVE(key_bindings, &key_bindings, bd);
cmd_list_free(bd->cmdlist);
xfree(bd);
key_bindings_remove(bd->key);
}
return (0);
}