X Tutup
Skip to content

Wayland: Fix trailing garbage error while using the embedder on Jay#113135

Merged
akien-mga merged 1 commit intogodotengine:masterfrom
deralmas:buffer-jaywalking
Nov 27, 2025
Merged

Wayland: Fix trailing garbage error while using the embedder on Jay#113135
akien-mga merged 1 commit intogodotengine:masterfrom
deralmas:buffer-jaywalking

Conversation

@deralmas
Copy link
Contributor

send_wayland_message takes in the number of words, not its byte size. This meant that we were sending quite a bit of out-of-bounds stuff alongside the four arguments required by xdg_positioner::set_anchor_rect, which triggered an assertion on Jay.

This didn't pop up before because the C wayland server library does not seem to check this, but it's a valid (and useful!) assertion for other server implementations nonetheless.

This patch switches to the initializer_list syntax to make the intent clearer.


Confirmed that fixes the editor on Jay. I'm not sure if there are other instances of this but, judging from the fact that body_len became unused I think we're in the clear for now :D

`send_wayland_message` takes in the number of words, not its byte size.
This meant that we were sending quite a bit of out-of-bounds stuff
alongside the four arguments required by
`xdg_positioner::set_anchor_rect`, which triggered an assertion on Jay.

This didn't pop up before because the C wayland server library does not
seem to check this, but it's a valid (and useful!) assertion
for other server implementations nonetheless.

This patch switches to the initializer_list syntax to make the intent
clearer.
@akien-mga akien-mga merged commit e28ef68 into godotengine:master Nov 27, 2025
20 checks passed
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

X Tutup