git.lucas.co / cce-compositor
Wayland compositor (wlroots)
git clone https://git.lucas.co/cce-compositor.git

commit91fc4cda70a5eb5f9089518a3471955b58e3e11f
parentf362312838
authorIsaac Freund <[email protected]>
date2025-12-19 23:39
XdgToplevel: initialize geometry

Currently we branch on this undefined memory if the first configure
times out.

 river/XdgToplevel.zig | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/river/XdgToplevel.zig b/river/XdgToplevel.zig
index c109932..d1bb9b7 100644
--- a/river/XdgToplevel.zig
+++ b/river/XdgToplevel.zig
@@ -40,8 +40,7 @@ wlr_toplevel: *wlr.XdgToplevel,
 
 decoration: ?XdgDecoration = null,
 
-/// Initialized on map
-geometry: wlr.Box = undefined,
+geometry: wlr.Box = .{ .x = 0, .y = 0, .width = 0, .height = 0 },
 
 configure_state: union(enum) {
     /// No configure has been sent since the last configure was acked.