Git log: commit ec5a3c91e33eded5b4b7ee9f4a6229be6c31c866
Author: Héctor Orón Martínez <zumbi@debian.org>
Date: Mon Jul 22 10:52:33 2024 +0200
Release Debian version 1.23.0-1
Signed-off-by: Héctor Orón Martínez <zumbi@debian.org>
commit e6b2d5753db168e2d8dde8c7a741f3fde3776a62
Author: Héctor Orón Martínez <zumbi@debian.org>
Date: Mon Jul 22 10:00:33 2024 +0200
debian/libwayland-server0.symbols: refresh
Signed-off-by: Héctor Orón Martínez <zumbi@debian.org>
commit aca0784aa091ab200a8ca2dcf0367a5c41c61e9d
Author: Héctor Orón Martínez <zumbi@debian.org>
Date: Mon Jul 22 09:51:04 2024 +0200
debian/libwayland-client0.symbols: refresh
Signed-off-by: Héctor Orón Martínez <zumbi@debian.org>
commit 277244b2e939f08abea7160f831f5a23e719193f
Author: Héctor Orón Martínez <zumbi@debian.org>
Date: Mon Jul 22 09:35:29 2024 +0200
prepare upcoming release
Signed-off-by: Héctor Orón Martínez <zumbi@debian.org>
commit c1b3b6c8c3b6eee09e6121cc79b2d0a2865fc5e6
Merge: 1baba96 a156431
Author: Héctor Orón Martínez <zumbi@debian.org>
Date: Mon Jul 22 08:04:21 2024 +0200
Merge branch 'upstream-unstable' into debian-unstable
commit 1baba96bb5648a577036f5ce977c9d4513f14230
Author: Héctor Orón Martínez <zumbi@debian.org>
Date: Mon Jul 22 07:59:34 2024 +0200
Move wayland-scanner.pc to libwayland-bin
Acknowledge NMU. Thanks Helmut Grohne!
Signed-off-by: Héctor Orón Martínez <zumbi@debian.org>
commit a156431ea66fe67d69c9fbba8a8ad34dabbab81c
Author: Simon Ser <contact@emersion.fr>
Date: Thu May 30 20:59:51 2024 +0200
build: bump to version 1.23.0 for the official release
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 26c419e046a70521e07b849faae901c7521d90df
Author: Hugo Osvaldo Barrera <hugo@whynothugo.nl>
Date: Wed May 8 20:54:19 2024 +0200
protocol: clarify divergence in compositor behaviour
This is intended to only document the current situation. Whether further
behaviour will be defined is out of scope and left for protocol v7.
See: https://gitlab.freedesktop.org/wayland/wayland/-/merge_requests/363
Signed-off-by: Hugo Osvaldo Barrera <hugo@whynothugo.nl>
commit 0b1626f47346247afe09fbf65978fc237a305892
Author: Simon Ser <contact@emersion.fr>
Date: Thu May 23 18:12:41 2024 +0200
build: bump to version 1.22.93 for the RC1 release
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 4bade6293806986500c517d3b0df571b1bf95d2d
Author: Simon Ser <contact@emersion.fr>
Date: Mon Jun 5 11:59:31 2023 +0200
server: document wl_display_add_socket_fd() ownership
wl_socket_destroy() will close the socket.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 17965d99e85410f20896c8d353082bd88ba87569
Author: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
Date: Thu May 16 12:39:17 2024 +0300
server: Clarify fd ownership in wl_client_create()
It's unclear whether one needs to call close() if wl_client_create()
fails. Hopefully this change makes it more clear.
Signed-off-by: Vlad Zahorodnii <vlad.zahorodnii@kde.org>
commit f870320958dab7f577b16700e3cca57ea3283397
Author: Simon Ser <contact@emersion.fr>
Date: Thu May 9 16:50:40 2024 +0200
build: bump to version 1.22.92 for the beta release
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 9e4f25692792df679660b390324842c19c0031a5
Author: Julian Orth <ju.orth@gmail.com>
Date: Wed Apr 17 11:24:50 2024 +0200
protocol: explicitly describe wl_keyboard state
And the allowed state transitions.
There has been some confusion regarding which state transitions are
allowed. This change should clarify this.
Signed-off-by: Julian Orth <ju.orth@gmail.com>
commit 69633202180acce9d0d5ab4037d80291c71b2307
Author: Simon Ser <contact@emersion.fr>
Date: Thu Apr 25 17:46:07 2024 +0200
build: bump to version 1.22.91 for the alpha release
Signed-off-by: Simon Ser <contact@emersion.fr>
commit e60c631ff2860de1d9f064f4f438c0412a6dea6b
Author: Derek Foreman <derek.foreman@collabora.com>
Date: Sat Apr 20 11:21:04 2024 -0500
client: print debug events that have no listener
Currently WAYLAND_DEBUG text ignores events that have no listener.
It can be helpful to know when you're receiving unhandled events,
as you may have forgotten to add a listener, or adding a dispatch
may have magically seemed to fix code that doesn't appear to be
dispatching anything.
Signed-off-by: Derek Foreman <derek.foreman@collabora.com>
commit 9069af78a71f6b2aadb11334e5bef9a670a5043d
Author: Sebastian Wick <sebastian.wick@redhat.com>
Date: Wed Apr 3 16:20:47 2024 +0200
protocol: define content updates and their internal queue
Multiple protocols use the term content update without a fill
definition. It makes sense to define it in the core protocol so that not
every other protocol has to define it.
This is supposed to retain the current semantics and only changes the
documentation while defining new terms.
Signed-off-by: Sebastian Wick <sebastian.wick@redhat.com>
commit 6e1db539168562020203498d97f8222cd06a4a43
Author: Simon Ser <contact@emersion.fr>
Date: Wed Apr 17 13:39:27 2024 +0200
client: fix invalid doc command for WL_MARSHAL_FLAG_DESTROY
Fixes the following warning:
src/wayland-client-core.h:125: warning: Found non-existing group 'wl_proxy' for the command '@ingroup', ignoring command
"\memberof" cannot be used here because it only works on functions.
The docs for "\memberof" say that "\relates" works in a similar way.
While at it, use a "\" command instead of a "@" command for
consistency with the rest of the file.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 80c65f862f7919691d3b0d31810f5a40f8675f37
Author: Simon Ser <contact@emersion.fr>
Date: Mon Apr 8 13:32:31 2024 +0200
tests: add deprecated-since attributes
Add a new event and enum entry to small.xml with a deprecated-since
attribute to exercise the scanner code generation.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit da8e1bbc45bde2debc6c8a1f9e3c67cb964de968
Author: Simon Ser <contact@emersion.fr>
Date: Tue Mar 12 14:21:54 2024 +0100
protocol: mark wl_pointer.axis_discrete as deprecated
Since version 8, this event isn't sent anymore.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit ee12e69b8fb8c55460126e4e527eb4f7fee5526e
Author: Simon Ser <contact@emersion.fr>
Date: Wed Jul 19 12:50:34 2023 +0200
Add support for the deprecated-since XML attribute
This marks a request, event or enum entry as deprecated since a
given version.
Note that it's not clear what it means if an entry is deprecated
at some version, and the enum is used from some completely different
interface than where it was defined. However, that's a more general
issue with enums, see:
https://gitlab.freedesktop.org/wayland/wayland/-/issues/435
Signed-off-by: Simon Ser <contact@emersion.fr>
References: https://gitlab.freedesktop.org/wayland/wayland/-/issues/89
commit 16aee2ec3829b37f4db623ab9ddab1b789bdd2e2
Author: Chloé Vulquin <code@toast.bunkerlabs.net>
Date: Thu Mar 28 13:44:36 2024 +0100
xcursor: catch theme inheritance loops
As of currently, when an xcursor theme depends on itself or another theme
that will eventually depend on it, `xcursor_load_theme` will recurse
infinitely while processing the inherits.
This change introduces a stack-allocated linked list of visited nodes
by name, and skips any already visited nodes in the inherit list.
Side effects:
* Since the linked list is stack-allocated, there is a potential for an
overflow if there is a very long list of dependencies. If this turns out
to be a legitimate concern, the linked list is trivial to convert to
being heap-allocated.
* There is an existing linked list (technically doubly linked list)
implementation in the wayland codebase. As of currently, the xcursor
codebase does not refer to it. Consequently, this change writes a
minimal single linked list implementation to utilize directly.
This changeset fixes #317.
Signed-off-by: Chloé Vulquin <toast@bunkerlabs.net>
commit b258d5f36137088e5cb5ae097db7964290da7d55
Author: Simon Ser <contact@emersion.fr>
Date: Sat Sep 17 10:53:56 2022 +0200
scanner: add validators for enums
Right now compositors need to manually check that enum values sent
by the client are valid. In particular:
- Check that the value sent by the client is not outside of the enum.
- Check that the version of the enum entry is consistent with the
object version.
Automatically generate validator functions to perform these tasks.
Signed-off-by: Simon Ser <contact@emersion.fr>
Closes: https://gitlab.freedesktop.org/wayland/wayland/-/issues/104
commit 5eeaac6e1114fddeb36682ef1eead967c06e9b02
Author: Julian Orth <ju.orth@gmail.com>
Date: Tue Feb 27 14:21:05 2024 +0100
Clarify behavior of buffer transformations
The new text describes how
- Mutter
- Plasma
- Sway 1.8
- Jay
behave.
Sway 1.9 flipped the behavior of 90 degree and 270 degree
set_buffer_transform requests. [mpv] also changed the behavior of its
vo_wayland_dmabuf backend which makes it only work correctly on sway
1.9.
[mpv]: https://github.com/mpv-player/mpv/pull/12509
It seems that the previous text was open to interpretation or at least
caused some amount of confusion.
Signed-off-by: Julian Orth <ju.orth@gmail.com>
commit af1dc3ef4bbbc62675a68ff524edd577f2a56ece
Author: Colin Kinloch <colin.kinloch@collabora.com>
Date: Mon Apr 15 11:47:11 2024 +0100
protocol: Undefine wl_display_sync callback data
Signed-off-by: Colin Kinloch <colin.kinloch@collabora.com>
commit 03e304544b9b01c175813215f5930a07152be448
Author: 6t8k <6t8k@noreply.codeberg.org>
Date: Sat Oct 14 23:25:48 2023 +0200
cursor: memfd_create: try MFD_NOEXEC_SEAL
Effective from Linux 6.3 onward, this creates the memfd without execute
permissions and prevents that setting from ever being changed. A
run-time fallback is made to not using MFD_NOEXEC_SEAL when a
libwayland-cursor compiled on Linux >= 6.3 is run on Linux < 6.3.
This is a defense-in-depth security measure and silences a respective
kernel warning; see: https://lwn.net/Articles/918106/
This implementation is adopted from dnkl's `foot` terminal emulator.
Signed-off-by: 6t8k <6t8k@noreply.codeberg.org>
commit c5d145a602581ee70f3ee87566ccb5cf1ff6cce8
Author: Simon Ser <contact@emersion.fr>
Date: Thu Mar 28 15:40:05 2024 +0100
ci: turn on -Dwerror=true for FreeBSD
It was turned on for Linux only.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 37699a98b1ebdc488a880b41b4b712403293d5d7
Author: Simon Ser <contact@emersion.fr>
Date: Thu Mar 28 15:38:24 2024 +0100
ci: use --fatal-meson-warnings
Turns Meson warnings into errors. Useful to avoid missing warnings.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit e7df1f2af2ccc80a85d28b6b4064c6466e425bd0
Author: Simon Ser <contact@emersion.fr>
Date: Thu Mar 28 15:40:44 2024 +0100
build: bump minimum Meson version to 0.57
Fixes the following warning:
tests/meson.build:91: WARNING: Project targets '>= 0.56.0' but uses feature introduced in '0.57.0': env arg in run_target.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit ad4ed17335e62d0187362dcfe9d70dac886a8065
Author: Simon Ser <contact@emersion.fr>
Date: Thu Mar 28 15:45:45 2024 +0100
ci: bump Meson version to 0.57
Signed-off-by: Simon Ser <contact@emersion.fr>
commit d074d52902633d8700ce06b484508db0f8fba02b
Author: Manuel Stoeckl <code@mstoeckl.com>
Date: Sat Sep 25 22:34:44 2021 -0400
connection: Dynamically resize connection buffers
When using fixed size connection buffers, if either the client or the
server is sending requests faster than the other end can cope with, the
connection buffers will fill up, eventually killing the connection.
This can be a problem for example with Xwayland mapping a lot of
windows, faster than the Wayland compositor can cope with, or a
high-rate mouse flooding the Wayland client with pointer events.
To avoid the issue, resize the connection buffers dynamically when they
get full.
Both data and fd buffers are resized on demand.
The default max buffer size is controlled via the wl_display interface
while each client's connection buffer size is adjustable for finer
control.
The purpose is to explicitly have larger connection buffers for specific
clients such as Xwayland, or set a larger buffer size for the client
with pointer focus to deal with a higher input events rate.
v0: Manuel:
Dynamically resize connection buffers - Both data and fd buffers are
resized on demand.
v1: Olivier
1. Add support for unbounded buffers on the client side and growable
(yet limited) connection buffers on the server side.
2. Add the API to set the default maximum size and a limit for a given
client.
3. Add tests for growable connection buffers and adjustable limits.
v2: Additional fixes by John:
1. Fix the size calculation in ring_buffer_check_space()
2. Fix wl_connection_read() to return gracefully once it has read up to
the max buffer size, rather than returning an error.
3. If wl_connection_flush() fails with EAGAIN but the transmit
ring-buffer has space remaining (or can be expanded),
wl_connection_queue() should store the message rather than
returning an error.
4. When the receive ring-buffer is at capacity but more data is
available to be read, wl_connection_read() should attempt to
expand the ring-buffer in order to read the remaining data.
v3: Thomas Lukaszewicz <tluk@chromium.org>
Add a test for unbounded buffers
v4: Add a client API as well to force bounded buffers (unbounded
by default (Olivier)
v5: Simplify ring_buffer_ensure_space() (Sebastian)
Co-authored-by: Olivier Fourdan <ofourdan@redhat.com>
Co-authored-by: John Lindgren <john@jlindgren.net>
Co-authored-by: Sebastian Wick <sebastian@sebastianwick.net>
Signed-off-by: Manuel Stoeckl <code@mstoeckl.com>
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Signed-off-by: John Lindgren <john@jlindgren.net>
Signed-off-by: Sebastian Wick <sebastian@sebastianwick.net>
Closes: https://gitlab.freedesktop.org/wayland/wayland/-/issues/237
commit 36cef8653fe57eff7d38fc0f4877bb900b1a21ea
Author: Simon Ser <contact@emersion.fr>
Date: Thu Mar 28 15:33:41 2024 +0100
util: convert macros to inline functions
Functionally equivalent except the usual macro footguns are avoided
and type safety is increased.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 4945f2664fced2cb7b6d836169cfe6e87ee19b90
Author: Isaac Freund <mail@isaacfreund.com>
Date: Fri Mar 15 18:02:44 2024 +0100
wl_touch.cancel: document lack of frame event
This appears to be what at least wlroots-based compositors and kwin do
in practice. However, it's not abundantly clear from the protocol text
what the expected behavior here is. This patch fixes that.
Signed-off-by: Isaac Freund <mail@isaacfreund.com>
commit 2e0dbb7021f713924954c37537f7831791135c30
Author: Simon Ser <contact@emersion.fr>
Date: Wed May 3 16:52:55 2023 +0200
tests: add scanner test for enum-header
Signed-off-by: Simon Ser <contact@emersion.fr>
commit fbd7460737c9cbae943bbc5d68a0fc6ca753c4d8
Author: Simon Ser <contact@emersion.fr>
Date: Wed May 3 12:18:07 2023 +0200
scanner: add new enum-header mode
This generates a header with only enum definitions. This is useful
to share enum headers between libraries and library users.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 2621484037869c917621b9f961310f13c09fcc00
Author: Jordan Williams <jordan@jwillikers.com>
Date: Mon Mar 11 09:06:55 2024 -0500
egl: Disable symbols check for static builds
The symbols check only works for dynamic libraries.
When building statically, the test fails.
This is caused by the check filtering out non-dynamic symbols with nm.
This change skips the check when building only static libraries.
Signed-off-by: Jordan Williams <jordan@jwillikers.com>
commit 8a7ecd774c4032f30949665b42910c2d2cae53f2
Author: David Benjamin <davidben@google.com>
Date: Sun Mar 24 19:43:58 2024 -0400
util: fix undefined behavior in wl_array_for_each
If a wl_array has size zero, wl_array_for_each computes NULL + 0 to get
to the end pointer. This should be fine, and indeed it would be fine in
C++. But the C specification has a mistake here and it is actually
undefined behavior. See
https://davidben.net/2024/01/15/empty-slices.html
Clang's -fsanitize=undefined flags this. I ran into this in Chromium's
build with wayland-scanner on one of our XML files.
../../third_party/wayland/src/src/scanner.c:1853:2: runtime error: applying zero offset to null pointer
#0 0x55c979b8e02c in emit_code third_party/wayland/src/src/scanner.c:1853:2
#1 0x55c979b89323 in main third_party/wayland/src/src/scanner.c
#2 0x7f8dfdb8c6c9 in __libc_start_call_main csu/../sysdeps/nptl/libc_start_call_main.h:58:16
#3 0x7f8dfdb8c784 in __libc_start_main csu/../csu/libc-start.c:360:3
#4 0x55c979b70f39 in _start (...)
An empty XML file is sufficient to hit this case, so I've added it as a
test. To reproduce, undo the fix and include only the test, then build
with:
CC=clang CFLAGS="-fno-sanitize-recover=undefined" meson build/ -Db_sanitize=undefined -Db_lundef=false
ninja -C build test
Signed-off-by: David Benjamin <davidben@google.com>
commit aa2a6d560bb2ec39b0643103942dc7b3dfa5976c
Author: Simon Ser <contact@emersion.fr>
Date: Wed Mar 6 11:19:09 2024 +0100
protocol: document that color channels provide electrical values
Expand the work done in [1] to document that all channels store
electrical values. See the discussion in [2].
[1]: https://gitlab.freedesktop.org/wayland/wayland/-/merge_requests/316
[2]: https://gitlab.freedesktop.org/wayland/wayland/-/merge_requests/250#note_2311377
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 44b1c0c737f3e877d98ea99459cda828bc1ff0a5
Author: Simon Ser <contact@emersion.fr>
Date: Wed Mar 6 19:08:53 2024 +0100
connection: use enum wl_arg_type in wl_message_count_arrays()
Missed it in 155dd63b58b8 ("Introduce enum wl_arg_type").
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 440defbd2ba3379b0519ce4f0381bdbe181ce58d
Author: Simon Ser <contact@emersion.fr>
Date: Tue Feb 27 12:30:03 2024 +0100
client: simplify create_proxies() loop
Decrease the indentation a bit. No functional change.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 7a1e7dd54963fad696aa7a1305440945ba3761d1
Author: Simon Ser <contact@emersion.fr>
Date: Tue Feb 27 12:28:39 2024 +0100
client: simplify create_outgoing_proxy() loop
Decrease the indentation a bit. No functional change.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 830883e5b2d3ec20a4f73258bdd97d12e5e9c9bc
Author: Simon Ser <contact@emersion.fr>
Date: Tue Feb 27 12:23:34 2024 +0100
connection: simplify wl_closure_lookup_objects() loop
Decrease the indentation a bit. No functional change.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 155dd63b58b8fc10d58fa03d6398d1673cea6062
Author: Simon Ser <contact@emersion.fr>
Date: Thu Feb 15 10:37:34 2024 +0100
Introduce enum wl_arg_type
This is less cryptic to read than letters, and allows the compiler
to check switch statements exhaustiveness.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 47de87263c88d3e23c7d7eb6d56ff75ddc8a02ef
Author: Thomas Lukaszewicz <tluk@chromium.org>
Date: Fri Jan 5 00:50:49 2024 +0000
Mitigate UAF crashes due to wl_client_destroy reentrancy
There are situations in which a call into wl_client_destroy() can
result in a reentrant call into wl_client_destroy() - which
results in UAF / double free crashes.
For example, this can occur in the following scenario.
1. Server receives a message notifying it that a client has
disconnected (WL_EVENT_HANGUP [1])
2. This beings client destruction with a call to wl_client_destroy()
3. wl_client_destroy() kicks off callbacks as client-associated
resources are cleaned up and their destructors and destruction
signals are invoked.
4. These callbacks eventually lead to an explicit call to
wl_display_flush_clients() as the server attempts to flush
events to other connected clients.
5. Since the client has already begun destruction, when it is
reached in the iteration the flush fails wl_client_destroy()
is called again [2].
This patch guards against this reentrant condition by removing
the client from the display's client list when wl_client_destroy()
is first called. This prevents access / iteration over the client
after wl_client_destroy() is called.
In the example above, wl_display_flush_clients() will pass over
the client currently undergoing destruction and the reentrant
call is avoided.
[1] https://gitlab.freedesktop.org/wayland/wayland/-/blob/8f499bf4045f88f3a4b4b0a445befca467bebe20/src/wayland-server.c#L342
[2] https://gitlab.freedesktop.org/wayland/wayland/-/blob/8f499bf4045f88f3a4b4b0a445befca467bebe20/src/wayland-server.c#L1512
Signed-off-by: Thomas Lukaszewicz [thomaslukaszewicz@gmail.com](mailto:thomaslukaszewicz@gmail.com)
commit d80bce5f1a0917c013aac54e3f951ffe740d0cbe
Author: Sébastien Marie <semarie@online.fr>
Date: Fri Jan 19 16:09:27 2024 +0000
build: fix build and provide compat for OpenBSD
- wayland-egl-abi-check: try to use llvm-nm first instead of BSD nm (incompatible options)
- avoid forcing _POSIX_C_SOURCE=200809L (SOCK_CLOEXEC become available)
- epoll(7) is provided by a userspace wrapper around kqueue(2) as FreeBSD
- when using SO_PEERCRED, the struct to use is `struct sockpeercred` instead of `struct ucred` on OpenBSD
- provide a compatibility layer for count_open_fds() using sysctl(2) as FreeBSD
Signed-off-by: Sebastien Marie <semarie@online.fr>
commit 791912c67867b84e15f7a70d5f716c9dd8c2c01b
Author: Sébastien Marie <semarie@online.fr>
Date: Fri Jan 19 16:08:21 2024 +0000
compat: prefer waitpid() over waitid()
while both are defined by POSIX, waitpid() is more common than waitid().
Signed-off-by: Sebastien Marie <semarie@online.fr>
commit a74aa93394a6d572eb48b1898658dad3e0c5f720
Author: Simon Ser <contact@emersion.fr>
Date: Wed Oct 25 13:25:44 2023 +0200
protocol: mention wl_surface events from wl_output.{scale,transform}
The wl_output events should not be used anymore for guessing the
preferred scale and transform of a surface. We have explicit events
for that now.
Signed-off-by: Simon Ser <contact@emersion.fr>
commit 9c4213ed3eb3942766712df936775d827b846d0b
Author: Sebastian Wick <sebastian@sebastianwick.net>
Date: Mon Oct 25 04:34:49 2021 +0200
server: add wl_client_get_user_data/wl_client_set_user_data
The only way to attach some data to a wl_client seems to be setting up a
destroy listener and use wl_container_of. Let's make it straight forward
to attach some data.
Having an explicit destroy callback for the user data makes managing the
user data lifetime much more convenient. All other callbacks, be they
wl_resource request listeners, destroy listeners or destructors, or
wl_client destroy listeners, can assume that the wl_client user data
still exists if it was set. Otherwise making that guarantee would be
complicated.
Co-authored-by: Pekka Paalanen <pekka.paalanen@collabora.com>
Signed-off-by: Sebastian Wick <sebastian@sebastianwick.net>
commit 6a7284c63234c465a194b23ad28d527fa997bbcc
Author: Kirill Primak <vyivel@eclair.cafe>
Date: Thu Jan 25 20:48:57 2024 +0300
event-loop: use wl_priv_signal for the destroy signal
Signed-off-by: Kirill Primak <vyivel@eclair.cafe>
commit d275bc7f84f1cffb62cfb31f55f00dc2c5968cc9
Author: Thomas Lukaszewicz <tluk@chromium.org>
Date: Mon Jan 8 00:36:10 2024 +0000
Mitigate UAF crashes due to iteration over freed wl_resources
Currently it is possible to iterate over client-owned resources
during client destruction that have had their associated memory
released.
This can occur when client code calls wl_client_destroy(). The
following sequence illustrates how this may occur.
1. The server initiates destruction of the connected client via
call to wl_client_destroy().
2. Resource destroy listeners / destructors are invoked and
resource memory is freed one resource at a time [1].
3. If a listener / destructor for a resource results in a call
to wl_client_for_each_resource(), the iteration will proceed
over resources that have been previously freed in step 2,
resulting in UAFs / crashes.
The issue is that resources remain in the client's object map
even after they have had their memory freed, and are removed
from the map only after each individual resource has had its
memory released.
This patch corrects this by ensuring resource destruction first
invokes listeners / destructors and then removing them from the
client's object map before releasing the associated memory.
[1] https://gitlab.freedesktop.org/wayland/wayland/-/blob/main/src/wayland-server.c?ref_type=heads#L928
Signed-off-by: Thomas Lukaszewicz thomaslukaszewicz@gmail.com
commit 8f499bf4045f88f3a4b4b0a445befca467bebe20
Author: Kirill Primak <vyivel@eclair.cafe>
Date: Fri Jan 19 13:34:37 2024 +0300
protocol: clarify pending wl_buffer destruction
This matches the current behavior of KWin, Mutter, and Weston.
References: https://gitlab.freedesktop.org/wayland/wayland/-/issues/387
Signed-off-by: Kirill Primak <vyivel@eclair.cafe>
commit 88ece8a44d13eb6c00bb1c7c3c7c5a8fce2c3f4b
Author: Mikhail Gusarov <dottedmag@dottedmag.net>
Date: Sat Apr 22 11:46:19 2023 +0200
doc: Improve wording for packed IDs
"is incompatible with the implementation in libwayland" is a common
source of confusion as evidenced by repeated discussions in IRC
channel.
Improve the wording by making clear that
- packing IDs is a protocol requirement
- there are implementations (including libwayland) that enforce it
Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net>
commit b42218f790033c496c48c7d5ba1f8421db794d0b
Author: Derek Foreman <derek.foreman@collabora.com>
Date: Fri Nov 10 14:21:48 2023 -0600
client: Allow setting names for queues
Allow setting a name for an event queue. The queue is used only for
printing additional debug information.
Debug output can now show the name of the event queue an event is
dispatched from, or the event queue of a proxy when a request is made.
Signed-off-by: Derek Foreman <derek.foreman@collabora.com>
commit 2f17d480e848dc8cbd047fab9f322f326da54df9
Author: Erik Chen <erikchen@chromium.org>
Date: Thu Sep 29 23:39:40 2022 +0000
connection: Spruce up logging for client errors.
Some code paths that lead to a client error and connection termination
have no associated logging, or insufficient logging. This makes it
difficult to understand what went wrong. This commit adds or supplements
logging for all these code paths.
Signed-off-by: Erik Chen <erikchen@chromium.org>
commit 9867bdb111f827e8e6f43e1c1111bb513811f3f1
Author: John Lindgren <john@jlindgren.net>
Date: Mon Feb 28 08:54:47 2022 -0500
connection: Small simplification to wl_connection_write()
wl_connection_write() contained an exact copy of the logic in
wl_connection_queue(). Simplify things by just calling
wl_connection_queue() from wl_connection_write().
Signed-off-by: John Lindgren <john@jlindgren.net>
commit 8c49ee311245cbe615061e5a20a5e11648be324f
Author: Andreas Cord-Landwehr <cordlandwehr@kde.org>
Date: Sat Sep 24 16:47:46 2022 +0200
Consider pkgconfig sysroot for pkgdatadir
For libs/cflags this is done automatically, but not for manually accessed
variables. This matches what wayland-protocols does.
Signed-off-by: Andreas Cord-Landwehr <cordlandwehr@kde.org>
commit fd42f70bafa26fcf6f39f034b581b35838be71aa
Author: Simon Ser <contact@emersion.fr>
Date: Tue Nov 21 16:59:20 2023 +0100
shm: implement version 2
This version adds a release request.
Signed-off-by: Simon Ser <contact@emersion.fr>