Fix crash when keyboard map changes and no keybindings exist.
Don't assume old tree is non-null and start rebinding it.
This commit is contained in:
parent
c885c9a676
commit
e4e7c2be52
1 changed files with 2 additions and 1 deletions
|
@ -313,7 +313,8 @@ void keyboard_rebind(void)
|
||||||
|
|
||||||
old = keyboard_firstnode;
|
old = keyboard_firstnode;
|
||||||
keyboard_firstnode = NULL;
|
keyboard_firstnode = NULL;
|
||||||
node_rebind(old);
|
if (old)
|
||||||
|
node_rebind(old);
|
||||||
|
|
||||||
tree_destroy(old);
|
tree_destroy(old);
|
||||||
set_curpos(NULL);
|
set_curpos(NULL);
|
||||||
|
|
Loading…
Reference in a new issue