You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-12-01 16:38:31 +00:00
Merge pull request #113135 from deralmas/buffer-jaywalking
Wayland: Fix trailing garbage error while using the embedder on Jay
This commit is contained in:
@@ -1207,7 +1207,6 @@ WaylandEmbedder::MessageStatus WaylandEmbedder::handle_request(LocalObjectHandle
|
|||||||
DEBUG_LOG_WAYLAND_EMBED(vformat("Client #%d -> %s::%s(%s) l0x%x g0x%x", client->socket, interface->name, message.name, message.signature, local_id, global_id));
|
DEBUG_LOG_WAYLAND_EMBED(vformat("Client #%d -> %s::%s(%s) l0x%x g0x%x", client->socket, interface->name, message.name, message.signature, local_id, global_id));
|
||||||
|
|
||||||
const uint32_t *body = msg_data + 2;
|
const uint32_t *body = msg_data + 2;
|
||||||
size_t body_len = msg_len - (WL_WORD_SIZE * 2);
|
|
||||||
|
|
||||||
if (registry_globals_names.has(global_id)) {
|
if (registry_globals_names.has(global_id)) {
|
||||||
int global_name = registry_globals_names[global_id];
|
int global_name = registry_globals_names[global_id];
|
||||||
@@ -1623,7 +1622,7 @@ WaylandEmbedder::MessageStatus WaylandEmbedder::handle_request(LocalObjectHandle
|
|||||||
// Args: int x, int y, int width, int height.
|
// Args: int x, int y, int width, int height.
|
||||||
pos_data->anchor_rect = Rect2i(body[0], body[1], body[2], body[3]);
|
pos_data->anchor_rect = Rect2i(body[0], body[1], body[2], body[3]);
|
||||||
|
|
||||||
send_wayland_message(compositor_socket, global_id, p_opcode, body, body_len);
|
send_wayland_message(compositor_socket, global_id, p_opcode, { body[0], body[1], body[2], body[3] });
|
||||||
return MessageStatus::HANDLED;
|
return MessageStatus::HANDLED;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user