diff --git a/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc b/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc index a8c86e267b..9e81df4ca8 100644 --- a/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc +++ b/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc @@ -650,7 +650,7 @@ void SharedScreenCastStreamPrivate::ProcessBuffer(pw_buffer* buffer) { const struct spa_meta_cursor* cursor = static_cast(spa_buffer_find_meta_data( spa_buffer, SPA_META_Cursor, sizeof(*cursor))); - if (spa_meta_cursor_is_valid(cursor)) { + if (cursor && spa_meta_cursor_is_valid(cursor)) { struct spa_meta_bitmap* bitmap = nullptr; if (cursor->bitmap_offset)