mirror of
https://github.com/swaywm/sway.git
synced 2025-11-07 13:29:56 -05:00
Fix management of bindings during reload
seat_execute_command needs to check the flags on `binding_copy`, as `binding` will be a dangling pointer after a reload command. handle_keyboard_key needs to set the next_repeat_binding for non-reloads prior to executing the command in case the binding is freed by the reload command.
This commit is contained in:
parent
49c937fc87
commit
32c7386b0f
2 changed files with 3 additions and 4 deletions
|
|
@ -329,7 +329,7 @@ void seat_execute_command(struct sway_seat *seat, struct sway_binding *binding)
|
|||
binding->command, results->error);
|
||||
}
|
||||
|
||||
if (binding->flags & BINDING_RELOAD) { // free the binding if we made a copy
|
||||
if (binding_copy->flags & BINDING_RELOAD) {
|
||||
free_sway_binding(binding_copy);
|
||||
}
|
||||
free_cmd_results(results);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue