diff options
author | Ryan Dwyer <ryandwyer1@gmail.com> | 2018-07-12 14:43:08 +1000 |
---|---|---|
committer | Ryan Dwyer <ryandwyer1@gmail.com> | 2018-07-12 14:43:08 +1000 |
commit | ee0e1b170ec1fce2c92a495293ff8aced83b0cb1 (patch) | |
tree | 0dfcd35ff8fdb8f7cbeeeb690fdd346b8dbb1df7 | |
parent | Merge pull request #2235 from emersion/wlr-surface-role (diff) | |
download | sway-ee0e1b170ec1fce2c92a495293ff8aced83b0cb1.tar.gz sway-ee0e1b170ec1fce2c92a495293ff8aced83b0cb1.tar.zst sway-ee0e1b170ec1fce2c92a495293ff8aced83b0cb1.zip |
Fix crash in seat code
Container will be NULL if launching swaylock.
-rw-r--r-- | sway/input/seat.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sway/input/seat.c b/sway/input/seat.c index be37258f..5e65ca70 100644 --- a/sway/input/seat.c +++ b/sway/input/seat.c | |||
@@ -669,7 +669,7 @@ void seat_set_focus_warp(struct sway_seat *seat, | |||
669 | // If we've focused a floating container, bring it to the front. | 669 | // If we've focused a floating container, bring it to the front. |
670 | // We do this by putting it at the end of the floating list. | 670 | // We do this by putting it at the end of the floating list. |
671 | // This must happen for both the pending and current children lists. | 671 | // This must happen for both the pending and current children lists. |
672 | if (container_is_floating(container)) { | 672 | if (container && container_is_floating(container)) { |
673 | list_move_to_end(container->parent->children, container); | 673 | list_move_to_end(container->parent->children, container); |
674 | if (container_has_ancestor(container, container->current.parent)) { | 674 | if (container_has_ancestor(container, container->current.parent)) { |
675 | list_move_to_end(container->parent->current.children, container); | 675 | list_move_to_end(container->parent->current.children, container); |