Codebase list wlroots / 812ab2e
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. Quantum 2 years ago
2 changed file(s) with 2 addition(s) and 2 deletion(s). Raw diff Collapse all Expand all
467467
468468 unsigned int vendor = 0, product = 0;
469469
470 const char *type_name;
470 const char *type_name = "unknown";
471471
472472 switch (type) {
473473 case WLR_INPUT_DEVICE_KEYBOARD:
474474 wlr_seat_pointer_notify_button(server->seat,
475475 event->time_msec, event->button, event->state);
476476 double sx, sy;
477 struct wlr_surface *surface;
477 struct wlr_surface *surface = NULL;
478478 struct tinywl_view *view = desktop_view_at(server,
479479 server->cursor->x, server->cursor->y, &surface, &sx, &sy);
480480 if (event->state == WLR_BUTTON_RELEASED) {