aboutsummaryrefslogtreecommitdiff
path: root/tinywl
diff options
context:
space:
mode:
authorQuantum <quantum2048@gmail.com>2021-12-01 02:31:45 -0500
committerQuantum <quantum2048@gmail.com>2021-12-01 02:39:14 -0500
commit812ab2e716dc7c1ac906a206709ce009ae30c45c (patch)
treef9189ab4f51b6936e9f28a1f819c9b392d5bdd4a /tinywl
parent611b9ca84331f3278cfc31e188a86ed117aadb82 (diff)
Fix uninitialized variable errors in release mode
When using `meson --buildtype=release`, `-Wextra -Werror` is passed. This includes `-Werror=maybe-uninitialized`, which complains about the instances fixed in this commit.
Diffstat (limited to 'tinywl')
-rw-r--r--tinywl/tinywl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tinywl/tinywl.c b/tinywl/tinywl.c
index 5ce7c4e8..48775740 100644
--- a/tinywl/tinywl.c
+++ b/tinywl/tinywl.c
@@ -475,7 +475,7 @@ static void server_cursor_button(struct wl_listener *listener, void *data) {
wlr_seat_pointer_notify_button(server->seat,
event->time_msec, event->button, event->state);
double sx, sy;
- struct wlr_surface *surface;
+ struct wlr_surface *surface = NULL;
struct tinywl_view *view = desktop_view_at(server,
server->cursor->x, server->cursor->y, &surface, &sx, &sy);
if (event->state == WLR_BUTTON_RELEASED) {