From 432560a1cd79156965874b414bde9a243bf7d3b1 Mon Sep 17 00:00:00 2001 From: urly3 Date: Tue, 25 Aug 2026 11:29:52 +0200 Subject: [PATCH] fix: freebsd still requires 1-indexed tty (#1048) ## What are the changes about? I thought it was working as intended but appears I just got lucky when testing. VT_ACTIVATE still wants them 1-indexed, so increase the parsed value respectively. My apologies! ## What existing issue(s) does this resolve? N/A ## Pre-requisites - [ x ] I have tested & confirmed the changes work locally - [ x ] I have read and fully adhere to the rules set in the contributing guidelines found in `CONTRIBUTING.md` Reviewed-on: https://codeberg.org/fairyglade/ly/pulls/1048 Reviewed-by: AnErrupTion --- ly-core/src/interop.zig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ly-core/src/interop.zig b/ly-core/src/interop.zig index 0cf5f09..1b0eea1 100644 --- a/ly-core/src/interop.zig +++ b/ly-core/src/interop.zig @@ -265,7 +265,7 @@ fn PlatformStruct() type { const dev_name = buf[0 .. len - 1]; if (std.mem.startsWith(u8, dev_name, "ttyv")) { - return try std.fmt.parseInt(u8, dev_name[dev_name.len - 1 ..], 16); + return try std.fmt.parseInt(u8, dev_name[dev_name.len - 1 ..], 16) + 1; } return error.NoTtyFound;