view: initialise x+y variables to handle edge case

This commit is contained in:
Johan Malm 2021-08-04 21:43:07 +01:00
parent 6a5deb628e
commit 7dc4ae36ca

View file

@ -147,7 +147,7 @@ view_move_to_edge(struct view *view, const char *direction)
struct border border = view_border(view);
struct wlr_box usable = output_usable_area_in_layout_coords(output);
int x, y;
int x = 0, y = 0;
if (!strcasecmp(direction, "left")) {
x = usable.x + border.left + GAP;
y = view->y;