From aafccf423d07a84c60adc89197ec605395312182 Mon Sep 17 00:00:00 2001 From: ston <2424284164@qq.com> Date: Tue, 10 Jan 2023 18:14:41 +0800 Subject: [PATCH] fix session type when starting wayland via tty --- libs/hbb_common/src/platform/linux.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/hbb_common/src/platform/linux.rs b/libs/hbb_common/src/platform/linux.rs index a6ae2a9e7..e82416309 100644 --- a/libs/hbb_common/src/platform/linux.rs +++ b/libs/hbb_common/src/platform/linux.rs @@ -74,7 +74,7 @@ fn get_display_server_of_session(session: &str) -> String { } else { "".to_owned() }; - if display_server.is_empty() { + if display_server.is_empty() || display_server == "tty" { // loginctl has not given the expected output. try something else. if let Ok(sestype) = std::env::var("XDG_SESSION_TYPE") { display_server = sestype;