Skip to content

Commit

Permalink
Fix gcc builds
Browse files Browse the repository at this point in the history
  • Loading branch information
AlanGriffiths committed Nov 24, 2023
1 parent 671890c commit 45c3490
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions examples/client/mir_shell_demo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -264,6 +264,9 @@ void globals::init()
xdg_wm_base_add_listener(globals::wm_base, &shell_listener, NULL);
}

// If building against newer Wayland protocol definitions we may miss trailing fields
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wmissing-field-initializers"
wl_callback_listener const window::frame_listener =
{
.done = [](void* ctx, auto... args) { static_cast<window*>(ctx)->handle_frame_callback(args...); },
Expand Down Expand Up @@ -293,6 +296,7 @@ wl_keyboard_listener const window::keyboard_listener =
[](void* self, auto... args) { static_cast<window*>(self)->handle_keyboard_modifiers(args...); },
[](void* self, auto... args) { static_cast<window*>(self)->handle_keyboard_repeat_info(args...); },
};
#pragma GCC diagnostic pop

void window::update_free_buffers(wl_buffer* buffer)
{
Expand Down

0 comments on commit 45c3490

Please sign in to comment.