Skip to content

Commit

Permalink
fixup! xw_set_geo_notify: Check if grabbed view is null first
Browse files Browse the repository at this point in the history
  • Loading branch information
serebit committed Jun 4, 2024
1 parent 96d3049 commit 9af5081
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/surface/xwayland_view.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ static void xwayland_surface_set_geometry_notify(wl_listener* listener, [[maybe_
XWaylandView& view = magpie_container_of(listener, view, set_geometry);

auto grabbed_view = view.server.grabbed_view.lock();
if (grabbed_view != nullptr && grabbed_view->get_wlr_surface() != view.get_wlr_surface()) {
if (grabbed_view == nullptr || grabbed_view->get_wlr_surface() != view.get_wlr_surface()) {
const wlr_xwayland_surface& surface = view.wlr;
if (view.curr_placement == VIEW_PLACEMENT_STACKING) {
view.previous = view.current;
Expand Down

0 comments on commit 9af5081

Please sign in to comment.