From 593cfa256c4026030d596256fc8de9fa7b2431b6 Mon Sep 17 00:00:00 2001 From: Gregory Anders Date: Sat, 11 Nov 2023 17:21:10 -0500 Subject: [PATCH] glfw: fix compile error --- src/apprt/glfw.zig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/apprt/glfw.zig b/src/apprt/glfw.zig index 7bf5a9e98..a4178dfb5 100644 --- a/src/apprt/glfw.zig +++ b/src/apprt/glfw.zig @@ -662,8 +662,9 @@ pub const Surface = struct { // Not supported except on Linux if (comptime builtin.os.tag != .linux) break :selection ""; - break :selection glfwNative.getX11SelectionString() orelse + const raw = glfwNative.getX11SelectionString() orelse return glfw.mustGetErrorCode(); + break :selection std.mem.span(raw); }, };